[vte/vte-0-36] emulation: Restore colors upon terminal reset.
- From: Egmont Koblinger <egmontkob src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vte/vte-0-36] emulation: Restore colors upon terminal reset.
- Date: Fri, 10 Jan 2014 01:45:38 +0000 (UTC)
commit a5fe6998b9fdcc9892a3dc8f53e70a5cf273d059
Author: Egmont Koblinger <egmont gmail com>
Date: Fri Jan 10 02:44:39 2014 +0100
emulation: Restore colors upon terminal reset.
https://bugzilla.gnome.org/show_bug.cgi?id=672210
src/vte.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/src/vte.c b/src/vte.c
index 8d04ea6..60dea9b 100644
--- a/src/vte.c
+++ b/src/vte.c
@@ -14383,8 +14383,9 @@ vte_terminal_reset(VteTerminal *terminal,
g_hash_table_destroy(pvt->dec_saved);
pvt->dec_saved = g_hash_table_new(NULL, NULL);
}
- /* Reset the color palette. */
- /* vte_terminal_set_default_colors(terminal); */
+ /* Reset the color palette. Only the 256 indexed colors, not the special ones.
+ * (XTerm doesn't reset the cursor color, the others are not alterable by escapes in vte.) */
+ memcpy(terminal->pvt->palette, terminal->pvt->default_palette, 256 *
sizeof(terminal->pvt->palette[0]));
/* Reset the default attributes. Reset the alternate attribute because
* it's not a real attribute, but we need to treat it as one here. */
pvt->screen = &pvt->alternate_screen;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]