On Wed, 28 May 2003, T. Alexander Popiel wrote:

> In message:  <[EMAIL PROTECTED]>
>              Chris Green <[EMAIL PROTECTED]> writes:
>
> >I know one can set the title of an rxvt window using an escape
> >sequence but is it possible to read it back?  This would be useful for
> >setting the name of the ksh/bash history file.
>
> A quick grep of the source for XFetchName shows that yes,
> there is a command (in command.c) to fetch the window title.

There _was_ a command.

> Digging around a bit, it looks like it'd be "<ESC>[21t", with
> <ESC> replaced with 0x1b.  I haven't tested that, though...

If you check src/command.c, you'll see that it's commented out (at least
in the CVS version).  This was done for security reasons to prevent rogue
applications from stuffing data into the command line from the title.

XFetchName() in src/main.c is only used for optimization to avoid setting
the title if the new and the old titles are equal.

-- 
Regards,
Pavel Roskin

Reply via email to