terminal: Window operations

Implement OSC 1 (set window title), and some basic CSI t window
operations.

Signed-off-by: Callum Lowcay <callum@callumscode.com>
This commit is contained in:
Callum Lowcay 2011-01-14 20:46:23 +13:00
parent 9d708b07e4
commit ef57a9b788
3 changed files with 87 additions and 3 deletions

View file

@ -1207,6 +1207,19 @@ window_set_keyboard_focus_handler(struct window *window,
window->keyboard_focus_handler = handler;
}
void
window_set_title(struct window *window, const char *title)
{
free((void*) window->title);
window->title = strdup(title);
}
const char *
window_get_title(struct window *window)
{
return window->title;
}
void
window_damage(struct window *window, int32_t x, int32_t y,
int32_t width, int32_t height)