aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--gtk/PlatGTK.cxx10
-rw-r--r--gtk/ScintillaGTK.cxx4
2 files changed, 6 insertions, 8 deletions
diff --git a/gtk/PlatGTK.cxx b/gtk/PlatGTK.cxx
index 797538e93..c6fe2b1fd 100644
--- a/gtk/PlatGTK.cxx
+++ b/gtk/PlatGTK.cxx
@@ -56,15 +56,13 @@ struct LOGFONT {
#if USE_LOCK
static GMutex *fontMutex = NULL;
-#endif
static void InitializeGLIBThreads() {
-#if USE_LOCK
if (!g_thread_supported()) {
g_thread_init(NULL);
}
-#endif
}
+#endif
static void FontMutexAllocate() {
#if USE_LOCK
@@ -1119,7 +1117,7 @@ void SurfaceImpl::MeasureWidths(Font &font_, const char *s, int len, int *positi
#ifdef USE_PANGO
if (PFont(font_)->pfd) {
if (len == 1) {
- int width = PFont(font_)->CharWidth(*s);
+ int width = PFont(font_)->CharWidth(*s, et);
if (width) {
positions[0] = width;
return;
@@ -1137,7 +1135,7 @@ void SurfaceImpl::MeasureWidths(Font &font_, const char *s, int len, int *positi
}
} else {
int wclen = 0;
- if (dbcsMode) {
+ if (et == dbcs) {
GdkWChar *wctext = new GdkWChar[len + 1];
GdkWChar *wcp = wctext;
wclen = gdk_mbstowcs(wcp, s, len);
@@ -1176,7 +1174,7 @@ void SurfaceImpl::MeasureWidths(Font &font_, const char *s, int len, int *positi
}
}
if (len == 1) {
- PFont(font_)->SetCharWidth(*s, positions[0]);
+ PFont(font_)->SetCharWidth(*s, positions[0], et);
}
return;
}
diff --git a/gtk/ScintillaGTK.cxx b/gtk/ScintillaGTK.cxx
index 2764a828f..fce22ab9b 100644
--- a/gtk/ScintillaGTK.cxx
+++ b/gtk/ScintillaGTK.cxx
@@ -49,7 +49,7 @@
#ifdef SCI_LEXER
#include <glib.h>
#include <gmodule.h>
-#include "ExternalLexer.h"
+//#include "ExternalLexer.h"
#endif
#if GTK_MAJOR_VERSION < 2
@@ -616,7 +616,7 @@ sptr_t ScintillaGTK::WndProc(unsigned int iMessage, uptr_t wParam, sptr_t lParam
#ifdef SCI_LEXER
case SCI_LOADLEXERLIBRARY:
- LexerManager::GetInstance()->Load(reinterpret_cast<const char*>( wParam ));
+ //LexerManager::GetInstance()->Load(reinterpret_cast<const char*>( wParam ));
break;
#endif