diff options
| author | nyamatongwe <devnull@localhost> | 2003-04-27 07:44:19 +0000 |
|---|---|---|
| committer | nyamatongwe <devnull@localhost> | 2003-04-27 07:44:19 +0000 |
| commit | dd8ef4dda4c28dc6273d7f1d0002e44d36d4eb29 (patch) | |
| tree | c62e71bfbaadaf5e772f46465fe67b05a57736d6 /gtk/PlatGTK.cxx | |
| parent | 7ec4d09df739591d81527e0d5103d52f7945088a (diff) | |
| download | scintilla-mirror-dd8ef4dda4c28dc6273d7f1d0002e44d36d4eb29.tar.gz | |
Using iconv to convert input into current character set.
Diffstat (limited to 'gtk/PlatGTK.cxx')
| -rw-r--r-- | gtk/PlatGTK.cxx | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/gtk/PlatGTK.cxx b/gtk/PlatGTK.cxx index b3bb534c3..275e2c40d 100644 --- a/gtk/PlatGTK.cxx +++ b/gtk/PlatGTK.cxx @@ -720,10 +720,10 @@ public: #ifdef USE_PANGO -static const char *CharacterSetID(int characterSet) { +const char *CharacterSetID(int characterSet) { switch (characterSet) { case SC_CHARSET_ANSI: - return "ASCII"; + return ""; case SC_CHARSET_DEFAULT: return "LATIN1"; case SC_CHARSET_BALTIC: @@ -1126,11 +1126,11 @@ void SurfaceImpl::DrawTextBase(PRectangle rc, Font &font_, int ybase, const char SetIconv(PFont(font_)->characterSet); utfForm = UTF8FromIconv(iconvh, s, len); } - if (!utfForm) { // DBCS failed so treat as locale - gsize w; // stub - utfForm = g_locale_to_utf8(s, len, NULL, &w, NULL); - useGFree = static_cast<bool>(utfForm); - }; + //~ if (!utfForm) { // DBCS failed so treat as locale + //~ gsize w; // stub + //~ utfForm = g_locale_to_utf8(s, len, NULL, &w, NULL); + //~ useGFree = static_cast<bool>(utfForm); + //~ }; if (!utfForm) { // g_locale_to_utf8 failed so treat as Latin1 utfForm = UTF8FromLatin1(s, len); } @@ -1269,11 +1269,11 @@ void SurfaceImpl::MeasureWidths(Font &font_, const char *s, int len, int *positi bool useGFree = false; SetIconv(PFont(font_)->characterSet); char *utfForm = UTF8FromIconv(iconvh, s, len); - if (!utfForm) { // iconv failed so treat as locale - gsize w; // stub - utfForm = g_locale_to_utf8(s, len, NULL, &w, NULL); - useGFree = static_cast<bool>(utfForm); - } + //~ if (!utfForm) { // iconv failed so treat as locale + //~ gsize w; // stub + //~ utfForm = g_locale_to_utf8(s, len, NULL, &w, NULL); + //~ useGFree = static_cast<bool>(utfForm); + //~ } if (!utfForm) { utfForm = UTF8FromLatin1(s, len); } @@ -1368,11 +1368,11 @@ int SurfaceImpl::WidthText(Font &font_, const char *s, int len) { SetIconv(PFont(font_)->characterSet); utfForm = UTF8FromIconv(iconvh, s, len); } - if (!utfForm) { // iconv failed so treat as locale - gsize w; - utfForm = g_locale_to_utf8(s, len, NULL, &w, NULL); - useGFree = static_cast<bool>(utfForm); - }; + //~ if (!utfForm) { // iconv failed so treat as locale + //~ gsize w; + //~ utfForm = g_locale_to_utf8(s, len, NULL, &w, NULL); + //~ useGFree = static_cast<bool>(utfForm); + //~ }; if (!utfForm) { // g_locale_to_utf8 failed so treat as Latin1 utfForm = UTF8FromLatin1(s, len); } |
