diff options
author | Sebastien Helleu <flashcode@flashtux.org> | 2011-02-01 08:24:08 +0100 |
---|---|---|
committer | Sebastien Helleu <flashcode@flashtux.org> | 2011-02-01 08:24:08 +0100 |
commit | 8392d2fbcc1396da47f13e6188aaba334a0afac8 (patch) | |
tree | 8b5e6c14400595b30508e9d1a4a95f4a02ba7a82 | |
parent | 142fc29e2529125ef0c436e83eb7a819f1ee6386 (diff) | |
download | weechat-8392d2fbcc1396da47f13e6188aaba334a0afac8.zip |
Fix terminal title when $TERM starts with "screen" (patch from sleo)
-rw-r--r-- | ChangeLog | 3 | ||||
-rw-r--r-- | src/gui/curses/gui-curses-window.c | 6 |
2 files changed, 5 insertions, 4 deletions
@@ -1,12 +1,13 @@ WeeChat ChangeLog ================= Sébastien Helleu <flashcode@flashtux.org> -v0.3.5-dev, 2011-01-31 +v0.3.5-dev, 2011-02-01 Version 0.3.5 (under dev!) -------------------------- +* core: fix terminal title when $TERM starts with "screen" * core: add some chars after cursor when scrolling input line: new option weechat.look.input_cursor_scroll (bug #21391) * core: dynamically allocate color pairs (extended colors can be used without diff --git a/src/gui/curses/gui-curses-window.c b/src/gui/curses/gui-curses-window.c index ad3e133be..0162d2b99 100644 --- a/src/gui/curses/gui-curses-window.c +++ b/src/gui/curses/gui-curses-window.c @@ -1465,10 +1465,10 @@ gui_window_set_title (const char *title) { printf ("\33]0;%s\7", title); } - else if (strcmp (envterm, "screen") == 0) + else if (strncmp (envterm, "screen", 6) == 0) { printf ("\033k%s\033\\", title); - /* tryning to set the title of a backgrounded xterm like terminal */ + /* trying to set the title of a backgrounded xterm like terminal */ printf ("\33]0;%s\7", title); } } @@ -1492,7 +1492,7 @@ gui_window_set_title (const char *title) { printf ("\33]0;%s\7", "Terminal"); } - else if (strcmp (envterm, "screen") == 0) + else if (strncmp (envterm, "screen", 6) == 0) { if (envshell) { |