diff options
author | Neil <nyamatongwe@gmail.com> | 2015-02-15 23:51:05 +1100 |
---|---|---|
committer | Neil <nyamatongwe@gmail.com> | 2015-02-15 23:51:05 +1100 |
commit | 4e705edb0910461ebe675eb57d8fd08cc94495ec (patch) | |
tree | 1752b16a47f18b341d6cc96a4bf09dd4a730c78d /src/PositionCache.cxx | |
parent | 982ee92ffbbd5c2f223a06ec5bf42910cefc4894 (diff) | |
download | scintilla-mirror-4e705edb0910461ebe675eb57d8fd08cc94495ec.tar.gz |
Add SC_INDICFLAG_VALUEFORE and INDIC_TEXTFORE to allow a wide range of indicator
colours and to change the colour of text.
Diffstat (limited to 'src/PositionCache.cxx')
-rw-r--r-- | src/PositionCache.cxx | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/src/PositionCache.cxx b/src/PositionCache.cxx index 666399503..860a780d9 100644 --- a/src/PositionCache.cxx +++ b/src/PositionCache.cxx @@ -440,7 +440,7 @@ void BreakFinder::Insert(int val) { } BreakFinder::BreakFinder(const LineLayout *ll_, const Selection *psel, Range lineRange_, int posLineStart_, - int xStart, bool breakForSelection, const Document *pdoc_, const SpecialRepresentations *preprs_) : + int xStart, bool breakForSelection, const Document *pdoc_, const SpecialRepresentations *preprs_, const ViewStyle *pvsDraw) : ll(ll_), lineRange(lineRange_), posLineStart(posLineStart_), @@ -475,7 +475,17 @@ BreakFinder::BreakFinder(const LineLayout *ll_, const Selection *psel, Range lin } } } - + if (pvsDraw && pvsDraw->indicatorsSetFore > 0) { + for (Decoration *deco = pdoc->decorations.root; deco; deco = deco->next) { + if (pvsDraw->indicators[deco->indicator].OverridesTextFore()) { + int startPos = deco->rs.EndRun(posLineStart); + while (startPos < (posLineStart + lineRange.end)) { + Insert(startPos - posLineStart); + startPos = deco->rs.EndRun(startPos); + } + } + } + } Insert(ll->edgeColumn); Insert(lineRange.end); saeNext = (!selAndEdge.empty()) ? selAndEdge[0] : -1; |