Fix folding in user-defined languages for non-windows line endings

Close #3372, fix #2873
This commit is contained in:
ssk97 2017-06-06 14:12:28 -07:00 committed by Don HO
parent 053823e8ca
commit dd401f1379
No known key found for this signature in database
GPG Key ID: 6C429F1D8D84F46E

View File

@ -2081,6 +2081,8 @@ static void ColouriseUserDoc(Sci_PositionU startPos, Sci_Position length, int in
// no closing sequence, start over from default // no closing sequence, start over from default
sc.SetState(SCE_USER_STYLE_IDENTIFIER); sc.SetState(SCE_USER_STYLE_IDENTIFIER);
dontMove = true; dontMove = true;
if (sc.atLineEnd)
checkEOL = EOL_SKIP_CHECK;
break; break;
} }
} }
@ -2125,7 +2127,7 @@ static void ColouriseUserDoc(Sci_PositionU startPos, Sci_Position length, int in
sc.SetState(SCE_USER_STYLE_IDENTIFIER); sc.SetState(SCE_USER_STYLE_IDENTIFIER);
dontMove = true; dontMove = true;
if (sc.atLineEnd) if (sc.atLineEnd)
checkEOL = true; checkEOL = EOL_SKIP_CHECK;
levelNext--; levelNext--;
if (levelMinCurrent > levelNext) if (levelMinCurrent > levelNext)
@ -2150,7 +2152,7 @@ static void ColouriseUserDoc(Sci_PositionU startPos, Sci_Position length, int in
// no closing sequence, start over from default // no closing sequence, start over from default
sc.SetState(SCE_USER_STYLE_IDENTIFIER); sc.SetState(SCE_USER_STYLE_IDENTIFIER);
if (sc.atLineEnd) if (sc.atLineEnd)
checkEOL = true; checkEOL = EOL_SKIP_CHECK;
dontMove = true; dontMove = true;
levelNext--; levelNext--;