Commit eb6079bc authored by Nalin Dahyabhai's avatar Nalin Dahyabhai

save the new codeset. compare the new codeset to the name of the UTF-8

* src/iso2022.c(_vte_iso2022_state_set_codeset): save the new codeset.
* src/iso2022.c(process_cdata): compare the new codeset to the name of the
	UTF-8 codeset instead of the local codeset to see if we need to notify
	callers of a change.
parent 8aacd3df
2003-04-23 nalin
* src/iso2022.c(_vte_iso2022_state_set_codeset): save the new codeset.
* src/iso2022.c(process_cdata): compare the new codeset to the name of
the UTF-8 codeset instead of the local codeset to see if we need to
notify callers of a change.
2003-04-23 nalin
* src/vte.c(vte_sequence_handler_sf): don't use the window freeze count
to check if it's safe to scroll using gdk_window_scroll(), require other
......
......@@ -19,6 +19,7 @@ Accessibility peer of #VteTerminal.
This should not be accessed directly. Use the #AtkText interface instead.
</para>
@parent:
<!-- ##### FUNCTION vte_terminal_accessible_new ##### -->
<para>
......
......@@ -684,7 +684,8 @@ _vte_iso2022_state_new(const char *native_codeset,
state->target_codeset = _vte_matcher_wide_encoding();
#ifdef VTE_DEBUG
if (_vte_debug_on(VTE_DEBUG_SUBSTITUTION)) {
fprintf(stderr, "%s\n", state->codeset);
fprintf(stderr, "Native codeset \"%s\", currently %s\n",
state->native_codeset, state->codeset);
}
#endif
state->conv = g_iconv_open(state->target_codeset,
......@@ -718,6 +719,7 @@ _vte_iso2022_state_set_codeset(struct _vte_iso2022_state *state,
return;
}
g_iconv_close(state->conv);
state->codeset = g_quark_to_string(g_quark_from_string(codeset));
state->conv = conv;
}
......@@ -1383,7 +1385,7 @@ process_control(struct _vte_iso2022_state *state, guchar *ctl, gsize length,
#endif
break;
case 'G':
if (strcmp(state->codeset, state->native_codeset) != 0) {
if (strcmp(state->codeset, state->utf8_codeset) != 0) {
notify = TRUE;
}
_vte_iso2022_state_set_codeset(state, state->utf8_codeset);
......
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