Use 64-bit positions instead of 32-bit obsolete ones
ref: https://github.com/notepad-plus-plus/notepad-plus-plus/pull/14359/files#r1437502252
This commit is contained in:
parent
c1fa9273e5
commit
8ae049afbc
|
@ -558,7 +558,7 @@ LRESULT ScintillaEditView::scintillaNew_Proc(HWND hwnd, UINT Message, WPARAM wPa
|
|||
size_t docLen = getCurrentDocLen();
|
||||
|
||||
char eolStr[3];
|
||||
Sci_TextRange tr;
|
||||
Sci_TextRangeFull tr;
|
||||
tr.chrg.cpMin = posStart;
|
||||
tr.chrg.cpMax = posEnd + 2;
|
||||
if (tr.chrg.cpMax > static_cast<Sci_PositionCR>(docLen))
|
||||
|
@ -568,7 +568,7 @@ LRESULT ScintillaEditView::scintillaNew_Proc(HWND hwnd, UINT Message, WPARAM wPa
|
|||
tr.lpstrText = eolStr;
|
||||
|
||||
if (tr.chrg.cpMin != tr.chrg.cpMax)
|
||||
execute(SCI_GETTEXTRANGE, 0, reinterpret_cast<LPARAM>(&tr));
|
||||
execute(SCI_GETTEXTRANGEFULL, 0, reinterpret_cast<LPARAM>(&tr));
|
||||
|
||||
// Remember EOL length
|
||||
// in the case of other characters let Scintilla do its job
|
||||
|
|
Loading…
Reference in New Issue