Archive of RubyForge sup-talk mailing list
 help / color / mirror / Atom feed
* [sup-talk] [PATCH] Fix for icon title in gnome terminal (possibly others)
@ 2008-03-05 10:11 Marcus Williams
  2008-03-26 16:11 ` William Morgan
  0 siblings, 1 reply; 4+ messages in thread
From: Marcus Williams @ 2008-03-05 10:11 UTC (permalink / raw)


The escape code used for terminal titles works mostly but it doesnt set
the icon title as well [1], which is useful when minimised. This patch makes
the escape code set both window and icon title so the task bar updates
correctly in the gnome terminal (and probably others).

[1] http://rtfm.etla.org/xterm/ctlseq.html (see Operating System Controls)
---
 lib/sup/buffer.rb |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/lib/sup/buffer.rb b/lib/sup/buffer.rb
index d40a626..978e104 100644
--- a/lib/sup/buffer.rb
+++ b/lib/sup/buffer.rb
@@ -263,7 +263,7 @@ EOS
         get_status_and_title @focus_buf # must be called outside of the ncurses lock
       end
 
-    print "\033]2;#{title}\07" if title && @in_x
+    print "\033]0;#{title}\07" if title && @in_x
 
     Ncurses.mutex.lock unless opts[:sync] == false
 
-- 
1.5.4.1



^ permalink raw reply	[flat|nested] 4+ messages in thread

* [sup-talk] [PATCH] Fix for icon title in gnome terminal (possibly others)
  2008-03-05 10:11 [sup-talk] [PATCH] Fix for icon title in gnome terminal (possibly others) Marcus Williams
@ 2008-03-26 16:11 ` William Morgan
  2008-04-01 10:07   ` Marcus Williams
  0 siblings, 1 reply; 4+ messages in thread
From: William Morgan @ 2008-03-26 16:11 UTC (permalink / raw)


Reformatted excerpts from Marcus Williams's message of 2008-03-05:
> The escape code used for terminal titles works mostly but it doesnt
> set the icon title as well [1], which is useful when minimised. This
> patch makes the escape code set both window and icon title so the task
> bar updates correctly in the gnome terminal (and probably others).

Reworked slightly (to avoid duplicating the conditional) and applied.
Thanks!

-- 
William <wmorgan-sup at masanjin.net>


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [sup-talk] [PATCH] Fix for icon title in gnome terminal (possibly others)
  2008-03-26 16:11 ` William Morgan
@ 2008-04-01 10:07   ` Marcus Williams
  2008-04-01 15:03     ` William Morgan
  0 siblings, 1 reply; 4+ messages in thread
From: Marcus Williams @ 2008-04-01 10:07 UTC (permalink / raw)


On 26.3.2008, William Morgan wrote:
> Reformatted excerpts from Marcus Williams's message of 2008-03-05:
> > The escape code used for terminal titles works mostly but it doesnt
> > set the icon title as well [1], which is useful when minimised. This
> > patch makes the escape code set both window and icon title so the task
> > bar updates correctly in the gnome terminal (and probably others).
> 
> Reworked slightly (to avoid duplicating the conditional) and applied.

I couldnt figure out what you meant when you said this but I just
checked the diff that went in and that explained it... My patch
removes the old escape code line and replaces it with a single line,
but your patch prints both escape codes. You only need the one in my
patch as that does both icon and window titles, so you should be able
to have the single line:

print "\033]0;#{title}\07" if title && @in_x

... the fifth char '0' in the escape code means window AND icon (1
would be icon, 2 would be window). Not sure if you misread the patch
or if I duffed up :)

Marcus


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [sup-talk] [PATCH] Fix for icon title in gnome terminal (possibly others)
  2008-04-01 10:07   ` Marcus Williams
@ 2008-04-01 15:03     ` William Morgan
  0 siblings, 0 replies; 4+ messages in thread
From: William Morgan @ 2008-04-01 15:03 UTC (permalink / raw)


Reformatted excerpts from Marcus Williams's message of 2008-04-01:
> Not sure if you misread the patch or if I duffed up :)

I misread the patch. Sorry about that! Should be fixed now.

-- 
William <wmorgan-sup at masanjin.net>


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2008-04-01 15:03 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-03-05 10:11 [sup-talk] [PATCH] Fix for icon title in gnome terminal (possibly others) Marcus Williams
2008-03-26 16:11 ` William Morgan
2008-04-01 10:07   ` Marcus Williams
2008-04-01 15:03     ` William Morgan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox