You are not logged in.
Hi everyone!
I use dwm as a window manager and XTerm as my terminal emulator. I wanted to do one thing I can't find how to:
I want the background of the terminal emulator to change depending on it's focus status. Let's say I want the background color to be #333 when it has focus and #000 when it hasn't.
Now I believe there are two options:
Either a terminal emulator (not necessarily XTerm) supports it or I use a transparent one and dwm sets the different colors for the background depending on the focus status.
Does anyone know if any of these is possible?
Thanks,
nDray
Last edited by nDray (2009-04-03 10:12:34)
Offline
I'm not sure, but urxvt may be able to do this.
Offline
Unless urxvt has such an option you can't do this without hacking the dwm source (and I don't mean the config file only).Thisis simply because dwm has no ruleset per application (apart from floating yes/no and tag). You would need to modify the XCrossing events to check for a specific window(urxvt in this case).
This may be of help http://tronche.com/gui/x/xlib/events/window-entry-exit/
After you've (succesfully) accomplished that, make urxvt 100% transparent and use the ROOT background to fake changing of urxvt bg (make dwm use xsetroot -solid "<any color you want>" when you Enter or Leave the urxvt window).
You might of course search and see if urxvt has this option first
Last edited by Wra!th (2009-04-03 05:57:28)
MacGregor DESPITE THEM!
7f 45 4c 46 01 01 01 00 00 00 00 00 00 00 00 00
Offline
dwm could do that for every window as urxvt would be the only transparent one in my display... I'll check that later, thank you!
And will also see if urxvt knows when it has focus and allows changing background colors... That first
Offline
Well, if you can do it in aterm easily by adding tinting and fading in ~/.Xdefaults for aterm.
aterm*tinting: #ffffff
aterm*fading: 50
That's an example for aterm. It does not work for xterm unfortunately.
Hah, sorry for providing alternatives for xterm. I personally use xterm also and I think I'll look around and play with xterm to see how to effectively do it.
Offline
Thank you Aprz! I was just reading the manpage for urxvt and seen that there was the option I wanted but for text only... I'll see if fading actually depends on focus and how to do it... I can find it myself in XTerm, don't bother for me!
Thanks again.
Offline
Aterm totally does it. Thank you very much!
Offline