OhmNomNom / thyme

A fork of mintty, for the modern world
GNU General Public License v3.0
0 stars 0 forks source link

Change title shortcut #241

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Very useful feature would be the possibility to modify window title by pressing 
a shortcut - a simple dialog could appear, where user would be able to edit 
current title. I know it is possible to set title from command line (--tile), 
but this is only possible to do only starting new shell, but not changing 
current one. This feature would be very useful when users are working with many 
windows and are reusing existing windows for different needs (and giving them 
sensible names). Everytime to quit not needed window and create a new one just 
to change its title - is a big overhead (at least for me)...

Thanks!
Laimonas

Original issue reported on code.google.com by cun...@gmail.com on 8 Jan 2011 at 6:52

GoogleCodeExporter commented 9 years ago
You can change it with the xterm control sequence for this, like so:

echo -ne '\e]0;Title\a'

Keep in mind that the bash prompt (i.e. the PS1 variable) contains that control 
sequence to set the title to the current working directory.

Original comment by andy.koppe on 8 Jan 2011 at 8:11

GoogleCodeExporter commented 9 years ago
As the bash prompt can reset my custom title set via "echo" - such feature 
still would make sense - custom set title should always have higher priority 
over everything, what happens on the shell... Something similar is also with 
Linux terminals like Gnome Terminal or Konsole - they also show title, set by 
bash prompt and it always changing accordingly to what user does there, but as 
soon as user sets custom title - then it remains, doesn't matter what bash or 
any other shell says...

Original comment by cun...@gmail.com on 8 Jan 2011 at 9:20

GoogleCodeExporter commented 9 years ago
Then again, if you don't want bash to change the title, just change its prompt. 
See also http://www.gnu.org/software/bash/manual/bashref.html#Printing-a-Prompt 
for all the things you can include in the bash prompt and hence also in the 
terminal title.

As far as I'm concerned, implementing a dialog for setting the title is too 
much work for too little gain.

Original comment by andy.koppe on 12 Jan 2011 at 9:11