aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authornyamatongwe <devnull@localhost>2000-10-13 12:09:26 +0000
committernyamatongwe <devnull@localhost>2000-10-13 12:09:26 +0000
commitc8d4b2060a80b4045d082056c062dd999ebf4886 (patch)
treea6d72cf162223d3851cca1e702f57ec45e582bbe
parent30709b3e3c1e83449978b5537ff01950966202ee (diff)
downloadscintilla-mirror-c8d4b2060a80b4045d082056c062dd999ebf4886.tar.gz
Better setting of charset for Eastern Europe and escape to allow
font to be specified completely with leading "-".
-rw-r--r--gtk/PlatGTK.cxx9
1 files changed, 8 insertions, 1 deletions
diff --git a/gtk/PlatGTK.cxx b/gtk/PlatGTK.cxx
index d0c298685..46bffeb72 100644
--- a/gtk/PlatGTK.cxx
+++ b/gtk/PlatGTK.cxx
@@ -148,7 +148,7 @@ static const char *CharacterSetName(int characterSet) {
case SC_CHARSET_DEFAULT: return "iso8859";
case SC_CHARSET_BALTIC: return "*";
case SC_CHARSET_CHINESEBIG5: return "*";
- case SC_CHARSET_EASTEUROPE: return "*";
+ case SC_CHARSET_EASTEUROPE: return "iso8859-2";
case SC_CHARSET_GB2312: return "gb2312.1980";
case SC_CHARSET_GREEK: return "adobe";
case SC_CHARSET_HANGUL: return "ksc5601.1987";
@@ -171,6 +171,13 @@ void Font::Create(const char *faceName, int characterSet,
int size, bool bold, bool italic) {
// TODO: take notice of characterSet
Release();
+ // If name of the font begins with a '-', assume, that it is
+ // a full fontspec.
+ if (faceName[0] == '-'){
+ id = gdk_font_load(faceName);
+ if (id)
+ return;
+ }
char fontspec[300];
fontspec[0] = '\0';
strcat(fontspec, "-*-");