Commit b7c74171 authored by Kevin Goodsell's avatar Kevin Goodsell Committed by Egmont Koblinger

emulation: Add support for OSC 112 (reset cursor color)

https://bugzilla.gnome.org/show_bug.cgi?id=640040
parent c7a76a9f
......@@ -537,6 +537,7 @@ struct _vte_capability_string _vte_xterm_capability_strings[] = {
{OSC "46;%s" BEL, "change-logfile", 0},
{OSC "50;#%d" BEL, "change-font-number", 0},
{OSC "50;%s" BEL, "change-font-name", 0},
{OSC "112" BEL, "reset-cursor-colors", 0},
/* Set text parameters, ST-terminated versions. */
{OSC ";%s" ST, "set-icon-and-window-title", 0}, /* undocumented default */
......@@ -558,6 +559,7 @@ struct _vte_capability_string _vte_xterm_capability_strings[] = {
{OSC "46;%s" ST, "change-logfile", 0},
{OSC "50;#%d" ST, "change-font-number", 0},
{OSC "50;%s" ST, "change-font-name", 0},
{OSC "112" ST, "reset-cursor-colors", 0},
/* These may be bogus, I can't find docs for them anywhere (#104154). */
{OSC "21;%s" BEL, "set-text-property-21", 0},
......
......@@ -11,6 +11,7 @@ if [ "$#" -eq 0 ] ; then
echo " 6 'uri' change current file uri"
echo " 7 'uri' change current directory uri"
echo " 12 'color' change cursor color"
echo " 112 reset cursor color"
exit
fi
args=
......
......@@ -78,6 +78,7 @@ struct vteseq_n_struct {
"utf-8-character-set", VTE_SEQUENCE_HANDLER(vte_sequence_handler_utf_8_charset)
"window-manipulation", VTE_SEQUENCE_HANDLER(vte_sequence_handler_window_manipulation)
"change-cursor-colors", VTE_SEQUENCE_HANDLER(vte_sequence_handler_change_cursor_color)
"reset-cursor-colors", VTE_SEQUENCE_HANDLER(vte_sequence_handler_reset_cursor_color)
"character-attributes", VTE_SEQUENCE_HANDLER(vte_sequence_handler_character_attributes)
"device-status-report", VTE_SEQUENCE_HANDLER(vte_sequence_handler_device_status_report)
"set-scrolling-region", VTE_SEQUENCE_HANDLER(vte_sequence_handler_set_scrolling_region)
......
......@@ -3540,6 +3540,13 @@ vte_sequence_handler_change_cursor_color (VteTerminal *terminal, GValueArray *pa
}
}
/* Reset the color of the cursor */
static void
vte_sequence_handler_reset_cursor_color (VteTerminal *terminal, GValueArray *params)
{
_vte_terminal_set_color_internal(terminal, VTE_CUR_BG, VTE_COLOR_SOURCE_ESCAPE, NULL);
}
/* Lookup tables */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment