From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103734,ffb0fb48546947c4 X-Google-Attributes: gid103734,public X-Google-Thread: fee84,ffb0fb48546947c4 X-Google-Attributes: gidfee84,public X-Google-ArrivalTime: 1994-10-16 05:12:40 PST Path: bga.com!news.sprintlink.net!howland.reston.ans.net!swrinde!pipex!sunic!news.funet.fi!news.cs.tut.fi!news.cc.tut.fi!news.cc.tut.fi!av From: av@kielo (Arto V. Viitanen) Newsgroups: comp.windows.x,comp.unix.osf.osf1 Subject: Re: Machine Name in The Title bar??? Date: 14 Oct 1994 06:52:20 GMT Organization: University of Tampere, Finland Distribution: world Message-ID: References: <37bpie$8sd@nyx10.cs.du.edu> <37jkes$12c8@whale.st.usm.edu> <37ju4u$dmc@lll-winken.llnl.gov> Reply-To: av@cs.uta.fi (Arto V. Viitanen) NNTP-Posting-Host: uta.fi In-reply-to: oberman@icaen.llnl.gov's message of Thu, 13 Oct 94 19:27:54 GMT Xref: bga.com comp.windows.x:12669 comp.unix.osf.osf1:4070 >>>>> "oberman" == oberman writes: In article <37ju4u$dmc@lll-winken.llnl.gov> oberman@icaen.llnl.gov writes: oberman> In Article <37jkes$12c8@whale.st.usm.edu> chambles@whale.st.usm.edu oberman> (John William Chambless) writes: >> Someone pointed out in email that Mike probably wanted a way to >> _dynamically_ change the window title, ie. have the window title change >> as he logged into a different machine. >> oberman> The strings you are interested are near the bottom of page 4. oberman> ]0;string changes both the title and the icon to "string" oberman> ]1;string changes both the icon to "string" oberman> ]2;string changes the title to "string" oberman> ]50;font changes the font to "font" oberman> is 33(8) and is 7. Yes, I use them to set my xterm title to contain current directory and machine. Depending on the machine I am, I use either tcsh or zsh. On tcsh, I have: alias precmd 'echo -n "^[]2;`pwd` ($HOST)^G"' Where ^[ is actually and ^G is actually . This is based on the fact, that tcsh evaluates precmd alias before it prints the prompt. On zsh, I have function precmd() { echo -n "^[]2;`pwd` ($HOST)^G" } since zsh uses function precmd for same efect as tcsh uses the alias. Arto V. Viitanen Internet: av@cs.uta.fi University Of Tampere, X.400: S=av;OU=cs;O=ut;ADMD=fumail;C=fi Finland http://www.uta.fi/~av/