Hardcode the terminals which accept "set window title"

terminfo does not have reliable information on this, so we hardcode a whitelist
of terminal type prefixes.  This is the list from Debian's default screenrc,
plus "screen" itself (which also covers tmux).

Closes #172.
Closes #191.
This commit is contained in:
Keegan McAllister
2012-04-16 00:17:53 -04:00
committed by Keith Winstein
parent feb352c809
commit c390ee9b80
3 changed files with 31 additions and 4 deletions
+4 -3
View File
@@ -42,9 +42,10 @@ std::string Display::new_frame( bool initialized, const Framebuffer &last, const
}
/* has icon name or window title changed? */
if ( (!initialized)
|| (f.get_icon_name() != frame.last_frame.get_icon_name())
|| (f.get_window_title() != frame.last_frame.get_window_title()) ) {
if ( has_title &&
( (!initialized)
|| (f.get_icon_name() != frame.last_frame.get_icon_name())
|| (f.get_window_title() != frame.last_frame.get_window_title()) ) ) {
/* set icon name and window title */
if ( f.get_icon_name() == f.get_window_title() ) {
/* write combined Icon Name and Window Title */