Andy Arbon <andy_at_andrewarbon.co.uk> writes:
> Hello,
>
> Firstly, I'm not 100% sure this is really on topic on the FVWM list for
> which I apologise, but it's definitely a related query.
>
> I am looking for a way to make it easier to tell the many xterms I
> always end up running apart in the window lists. What I am currently
> thinking of doing is changing the title of each xterm to something like
> "xterm (<username>) - <last issued command>"
>
> Using the environment variable PROMPT_COMMAND I can give bash a command
> to execute before it draws each prompt, which would seem to be the right
> time to do the change. What I don't know is how to change the xterm
> title from within bash - is it possible, and if so, how?
There is an escape sequence that changes the title.
This creates the "shdr" function to change the title:
function shdr { # changes screen title
# This would make Rumba hang, so only do for some TERMs:
if [ "$TERM" = "xterm" -o "$TERM" = "rxvt" ] ; then
print -n '\033]2;'$*'\07'
fi
}
>
> PS. If anyone else has any other ideas on how to solve the problem of
> making the xterms easier to tell apart I'd be interested to hear them.
I find that doing most of my work in XEmacs removes the need for
a host of xterms.
--
Dan Espen E-mail: dane_at_mk.telcordia.com
444 Hoes Lane Room RRC 1C-214 Phone: (732) 699-5570
Piscataway, NJ 08854
--
Visit the official FVWM web page at <URL: http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to majordomo_at_fvwm.org.
To report problems, send mail to fvwm-owner_at_fvwm.org.
Received on Fri Sep 13 2002 - 09:39:24 BST