diff options
author | Neil <nyamatongwe@gmail.com> | 2021-05-22 08:18:01 +1000 |
---|---|---|
committer | Neil <nyamatongwe@gmail.com> | 2021-05-22 08:18:01 +1000 |
commit | c8235ba0e0292f209a8233613669e2cff8de80da (patch) | |
tree | 117df121f92601300eeb2e9a047860384eb17d79 /src/LineMarker.cxx | |
parent | 7f8a8cfb32aecb70fe10ef26fe096f4092f7e673 (diff) | |
download | scintilla-mirror-c8235ba0e0292f209a8233613669e2cff8de80da.tar.gz |
Rename ColourAlpha to ColourRGBA to avoid clashes when a ColourAlpha typedef
will be published in externally visible header.
Diffstat (limited to 'src/LineMarker.cxx')
-rw-r--r-- | src/LineMarker.cxx | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/src/LineMarker.cxx b/src/LineMarker.cxx index a3ab16b1d..4b9037215 100644 --- a/src/LineMarker.cxx +++ b/src/LineMarker.cxx @@ -73,8 +73,8 @@ LineMarker &LineMarker::operator=(const LineMarker &other) { return *this; } -ColourAlpha LineMarker::BackWithAlpha() const noexcept { - return ColourAlpha(back, alpha); +ColourRGBA LineMarker::BackWithAlpha() const noexcept { + return ColourRGBA(back, alpha); } void LineMarker::SetXPM(const char *textForm) { @@ -98,7 +98,7 @@ enum class Expansion { Minus, Plus }; enum class Shape { Square, Circle }; void DrawSymbol(Surface *surface, Shape shape, Expansion expansion, PRectangle rcSymbol, XYPOSITION widthStroke, - ColourAlpha colourFill, ColourAlpha colourFrame, ColourAlpha colourFrameRight, ColourAlpha colourExpansion) { + ColourRGBA colourFill, ColourRGBA colourFrame, ColourRGBA colourFrameRight, ColourRGBA colourExpansion) { const FillStroke fillStroke(colourFill, colourFrame, widthStroke); const PRectangle rcSymbolLeft = Side(rcSymbol, Edge::left, (rcSymbol.Width() + widthStroke) / 2.0f); @@ -137,7 +137,7 @@ void DrawSymbol(Surface *surface, Shape shape, Expansion expansion, PRectangle r } } -void DrawTail(Surface *surface, XYPOSITION leftLine, XYPOSITION rightTail, XYPOSITION centreY, XYPOSITION widthSymbolStroke, ColourAlpha fill) { +void DrawTail(Surface *surface, XYPOSITION leftLine, XYPOSITION rightTail, XYPOSITION centreY, XYPOSITION widthSymbolStroke, ColourRGBA fill) { const XYPOSITION slopeLength = 2.0f + widthSymbolStroke; const XYPOSITION strokeTop = centreY + slopeLength; const XYPOSITION halfWidth = widthSymbolStroke / 2.0f; @@ -158,9 +158,9 @@ void LineMarker::DrawFoldingMark(Surface *surface, const PRectangle &rcWhole, Fo // Assume: edges of rcWhole are integers. // Code can only really handle integer strokeWidth. - ColourAlpha colourHead = back; - ColourAlpha colourBody = back; - ColourAlpha colourTail = back; + ColourRGBA colourHead = back; + ColourRGBA colourBody = back; + ColourRGBA colourTail = back; switch (part) { case FoldPart::head: @@ -258,11 +258,11 @@ void LineMarker::DrawFoldingMark(Surface *surface, const PRectangle &rcWhole, Fo break; case SC_MARK_BOXPLUSCONNECTED: { - const ColourAlpha colourBelow = (part == FoldPart::headWithTail) ? colourTail : colourBody; + const ColourRGBA colourBelow = (part == FoldPart::headWithTail) ? colourTail : colourBody; surface->FillRectangle(rcBelowSymbol, colourBelow); surface->FillRectangle(rcAboveSymbol, colourBody); - const ColourAlpha colourRight = (part == FoldPart::body) ? colourTail : colourHead; + const ColourRGBA colourRight = (part == FoldPart::body) ? colourTail : colourHead; DrawSymbol(surface, Shape::Square, Expansion::Plus, rcSymbol, widthStroke, fore, colourHead, colourRight, colourTail); } @@ -278,7 +278,7 @@ void LineMarker::DrawFoldingMark(Surface *surface, const PRectangle &rcWhole, Fo surface->FillRectangle(rcBelowSymbol, colourHead); surface->FillRectangle(rcAboveSymbol, colourBody); - const ColourAlpha colourRight = (part == FoldPart::body) ? colourTail : colourHead; + const ColourRGBA colourRight = (part == FoldPart::body) ? colourTail : colourHead; DrawSymbol(surface, Shape::Square, Expansion::Minus, rcSymbol, widthStroke, fore, colourHead, colourRight, colourTail); } @@ -290,11 +290,11 @@ void LineMarker::DrawFoldingMark(Surface *surface, const PRectangle &rcWhole, Fo break; case SC_MARK_CIRCLEPLUSCONNECTED: { - const ColourAlpha colourBelow = (part == FoldPart::headWithTail) ? colourTail : colourBody; + const ColourRGBA colourBelow = (part == FoldPart::headWithTail) ? colourTail : colourBody; surface->FillRectangle(rcBelowSymbol, colourBelow); surface->FillRectangle(rcAboveSymbol, colourBody); - const ColourAlpha colourRight = (part == FoldPart::body) ? colourTail : colourHead; + const ColourRGBA colourRight = (part == FoldPart::body) ? colourTail : colourHead; DrawSymbol(surface, Shape::Circle, Expansion::Plus, rcSymbol, widthStroke, fore, colourHead, colourRight, colourTail); } @@ -309,7 +309,7 @@ void LineMarker::DrawFoldingMark(Surface *surface, const PRectangle &rcWhole, Fo case SC_MARK_CIRCLEMINUSCONNECTED: { surface->FillRectangle(rcBelowSymbol, colourHead); surface->FillRectangle(rcAboveSymbol, colourBody); - const ColourAlpha colourRight = (part == FoldPart::body) ? colourTail : colourHead; + const ColourRGBA colourRight = (part == FoldPart::body) ? colourTail : colourHead; DrawSymbol(surface, Shape::Circle, Expansion::Minus, rcSymbol, widthStroke, fore, colourHead, colourRight, colourTail); } |