Re: Gnome Terminal Suggestion/Question



The ZvtTerm widget is the terminal emulator inside gnome-terminal.

To set the title for the xterm you use the following escape sequence
(replacing \xxx with the equivalent character and _string_ with the
desired value):
  \033]2;_string_\077

If this is echoed to an xterm terminal, it will display the string in the
title bar.  You could use this in your PS1 to display some information for
instance.

Gnome-terminal doesn't support this yet (and it may break binary
compatibility to add it -- maybe this should go on the list for 1.1).

James Henstridge.

--
Email: james@daa.com.au
WWW:   http://www.daa.com.au/~james/


On Mon, 29 Mar 1999, Kevin Atkinson wrote:

> James Henstridge wrote:
> > 
> > Sorry about that last message.  I pressed the wrong button.
> > gnome-terminal currently only knows about the shell process it spawned.
> > The shell handles which processes are stoped/running/current.  So to get
> > the desired effect, the shell would have to tell gnome-terminal what to
> > put in the title bar.
> >
> > In xterm, there is an escape sequence that you can use to change the title
> > bar (console MC uses this).  I don't think gnome-terminal recognises this
> > sequence though.  If you use xterm, or the ZvtTerm widget was extended to
> > handle this escape sequence, you may be able to get the desired effect by
> > setting PS1.
> 
> What is the ZvtTerm widget?
> 
> Would it be possible to write shell script to send the escape sequence
> when ever a command is executed?
> 
> Also how difficult would it be to get gnome-terminal to recognize this
> sequence?  In addition a menu item to change the title bar would be
> appreciated.
> 
> Also is it possible to find out the current foreground process in a
> terminal using libgtop or even ps?
> 
> -- 
> Kevin Atkinson
> kevinatk@home.com
> http://metalab.unc.edu/kevina/
> 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]