ChicoTeam/pianobar — Issue #14: Titlebar changes with song
Author: nkrp
Created: 2012-02-07 04:32:15+00:00
State: open
Labels: Feature

cmus does this: http://cmus.sourceforge.net/

Here is how cmus does it:
(file: ui_curses.c line 1255)

static void set_title(const char *title)
{
if (!set_term_title)
return;

if (t_ts) {
printf("%s%s%s", tgoto(t_ts, 0, 0), title, t_fs);
fflush(stdout);
}
}
Other possibly useful info: http://www.ibiblio.org/pub/Linux/docs/HOWTO/Xterm-Title

Workaround: echo -e "format_nowplaying_song = \033]2;%t by %a\007" >> config