From 031f4b06578a4a5b7b6a686e340f76b8d26b9853 Mon Sep 17 00:00:00 2001 From: Lspeciosum Date: Wed, 17 Jun 2015 21:46:58 +0900 Subject: [PATCH] Scintilla new requires UTF-8 font-names (closes #220) Present version scintilla(x>3.5.3) accepts a font name only in utf-8. See also: - http://sourceforge.net/p/scintilla/bugs/1684/ - http://www.scintilla.org/ScintillaHistory.html --- PowerEditor/src/ScitillaComponent/ScintillaEditView.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PowerEditor/src/ScitillaComponent/ScintillaEditView.cpp b/PowerEditor/src/ScitillaComponent/ScintillaEditView.cpp index f85d9c27..6a5dc843 100644 --- a/PowerEditor/src/ScitillaComponent/ScintillaEditView.cpp +++ b/PowerEditor/src/ScitillaComponent/ScintillaEditView.cpp @@ -441,7 +441,7 @@ void ScintillaEditView::setSpecialStyle(const Style & styleToSet) if (styleToSet._fontName && lstrcmp(styleToSet._fontName, TEXT("")) != 0) { WcharMbcsConvertor *wmc = WcharMbcsConvertor::getInstance(); - const char * fontNameA = wmc->wchar2char(styleToSet._fontName, CP_ACP); + const char * fontNameA = wmc->wchar2char(styleToSet._fontName, CP_UTF8); execute(SCI_STYLESETFONT, (WPARAM)styleID, (LPARAM)fontNameA); } int fontStyle = styleToSet._fontStyle;