From ce34c904cc09680689337156dd23114e27318103 Mon Sep 17 00:00:00 2001 From: Corinna Vinschen Date: Wed, 15 Oct 2003 08:23:26 +0000 Subject: * fhandler_console.cc (char_command): Add escape sequence for codepage ansi <-> oem switching for ncurses frame drawing capabilities. * dcrt0.cc: Add local variable alternate_charset_active. * winsup.h: Add global external variable alternate_charset_active. --- winsup/cygwin/fhandler_console.cc | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'winsup/cygwin/fhandler_console.cc') diff --git a/winsup/cygwin/fhandler_console.cc b/winsup/cygwin/fhandler_console.cc index e80e47be4..24c59c7d6 100644 --- a/winsup/cygwin/fhandler_console.cc +++ b/winsup/cygwin/fhandler_console.cc @@ -66,6 +66,12 @@ con_to_str (char *d, const char *s, DWORD sz) inline BOOL str_to_con (char *d, const char *s, DWORD sz) { + if (alternate_charset_active) + { + /* no translation when alternate charset is active */ + memcpy(d, s, sz); + return TRUE; + } return cp_convert (GetConsoleOutputCP (), d, get_cp (), s, sz); } @@ -1111,6 +1117,12 @@ fhandler_console::char_command (char c) case 9: /* dim */ dev_state->intensity = INTENSITY_DIM; break; + case 10: /* end alternate charset */ + alternate_charset_active = FALSE; + break; + case 11: /* start alternate charset */ + alternate_charset_active = TRUE; + break; case 24: dev_state->underline = FALSE; break; -- cgit v1.2.3