Change an active Terminal's background color

Harold Aling h.aling at home.nl
Thu Feb 1 20:58:07 CET 2007


Dear list,

(How) can I change the background color of a running Terminal? I 
currently use xterm and when I sudo a command or ssh to a machine, I use 
xtermcontrol to set different backgroundcolors so I don't have to look 
at the prompt on which system I am working on...

Current .bashrc config:

ssh () {
        xtermOldBG=`xtermcontrol --get-bg`
        xtermcontrol --bg="darkred"
        command ssh "$@"
        xtermcontrol --bg=${xtermOldBG}
}

sudo () {
        xtermOldBG=`xtermcontrol --get-bg`
        xtermcontrol --bg="darkblue"
        command su "$@"
        xtermcontrol --bg=${xtermOldBG}
}

I'd like to replace xterm with Terminal, but not if Terminal can't 
change it's background color on-the-fly...


Cheers!

-H-



More information about the Xfce mailing list