diff --git a/PowerEditor/src/Notepad_plus.cpp b/PowerEditor/src/Notepad_plus.cpp index 0909720c..590a37c4 100644 --- a/PowerEditor/src/Notepad_plus.cpp +++ b/PowerEditor/src/Notepad_plus.cpp @@ -2456,8 +2456,10 @@ void Notepad_plus::addHotSpot(ScintillaEditView* view) int urlAction = (NppParameters::getInstance()).getNppGUI()._styleURL; LPARAM indicStyle = (urlAction == 2) ? INDIC_PLAIN : INDIC_HIDDEN; - pView->execute(SCI_INDICSETSTYLE, URL_INDIC, indicStyle); - pView->execute(SCI_INDICSETHOVERSTYLE, URL_INDIC, INDIC_FULLBOX); + + LPARAM indicStyleCur = pView->execute(SCI_INDICGETSTYLE, URL_INDIC); + if (indicStyleCur != indicStyle) + pView->execute(SCI_INDICSETSTYLE, URL_INDIC, indicStyle); int startPos = 0; int endPos = -1; diff --git a/PowerEditor/src/ScitillaComponent/ScintillaEditView.cpp b/PowerEditor/src/ScitillaComponent/ScintillaEditView.cpp index 1de04b90..4d8ed439 100644 --- a/PowerEditor/src/ScitillaComponent/ScintillaEditView.cpp +++ b/PowerEditor/src/ScitillaComponent/ScintillaEditView.cpp @@ -329,6 +329,8 @@ void ScintillaEditView::init(HINSTANCE hInst, HWND hPere) execute(SCI_INDICSETUNDER, SCE_UNIVERSAL_FOUND_STYLE_EXT4, true); execute(SCI_INDICSETUNDER, SCE_UNIVERSAL_FOUND_STYLE_EXT5, true); + execute(SCI_INDICSETHOVERSTYLE, URL_INDIC, INDIC_FULLBOX); + _codepage = ::GetACP(); ::SetWindowLongPtr(_hSelf, GWLP_USERDATA, reinterpret_cast(this));