diff options
author | Marko Njezic <devnull@localhost> | 2012-02-17 23:59:20 +0100 |
---|---|---|
committer | Marko Njezic <devnull@localhost> | 2012-02-17 23:59:20 +0100 |
commit | 8fd74650b45775cdd3e34d41fe60c206a4310dbd (patch) | |
tree | d9a9e7d2dd198392decf1abcc371aa9d00372af6 /src/LineMarker.cxx | |
parent | 948f0a4a090e1caed33d52065654a48e508c4883 (diff) | |
download | scintilla-mirror-8fd74650b45775cdd3e34d41fe60c206a4310dbd.tar.gz |
Draw markers horizontally off center only on textual margins. Bug #3488696.
Diffstat (limited to 'src/LineMarker.cxx')
-rw-r--r-- | src/LineMarker.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/LineMarker.cxx b/src/LineMarker.cxx index de9968fab..e10e69142 100644 --- a/src/LineMarker.cxx +++ b/src/LineMarker.cxx @@ -68,7 +68,7 @@ static void DrawMinus(Surface *surface, int centreX, int centreY, int armSize, C surface->FillRectangle(rcH, fore); } -void LineMarker::Draw(Surface *surface, PRectangle &rcWhole, Font &fontForCharacter, typeOfFold tFold) { +void LineMarker::Draw(Surface *surface, PRectangle &rcWhole, Font &fontForCharacter, typeOfFold tFold, int marginStyle) { ColourDesired head = back; ColourDesired body = back; ColourDesired tail = back; @@ -112,8 +112,8 @@ void LineMarker::Draw(Surface *surface, PRectangle &rcWhole, Font &fontForCharac int dimOn4 = minDim / 4; int blobSize = dimOn2-1; int armSize = dimOn2-2; - if (rc.Width() > (rc.Height() * 2)) { - // Wide column is line number so move to left to try to avoid overlapping number + if (marginStyle == SC_MARGIN_NUMBER || marginStyle == SC_MARGIN_TEXT || marginStyle == SC_MARGIN_RTEXT) { + // On textual margins move marker to the left to try to avoid overlapping the text centreX = rc.left + dimOn2 + 1; } if (markType == SC_MARK_ROUNDRECT) { |