diff options
Diffstat (limited to 'src/Indicator.h')
-rw-r--r-- | src/Indicator.h | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/Indicator.h b/src/Indicator.h index 11851476e..fc17a82c2 100644 --- a/src/Indicator.h +++ b/src/Indicator.h @@ -8,14 +8,14 @@ #ifndef INDICATOR_H #define INDICATOR_H -namespace Scintilla { +namespace Scintilla::Internal { struct StyleAndColour { - int style; + Scintilla::IndicatorStyle style; ColourRGBA fore; - StyleAndColour() noexcept : style(INDIC_PLAIN), fore(0, 0, 0) { + StyleAndColour() noexcept : style(Scintilla::IndicatorStyle::Plain), fore(0, 0, 0) { } - StyleAndColour(int style_, ColourRGBA fore_ = ColourRGBA(0, 0, 0)) noexcept : style(style_), fore(fore_) { + StyleAndColour(Scintilla::IndicatorStyle style_, ColourRGBA fore_ = ColourRGBA(0, 0, 0)) noexcept : style(style_), fore(fore_) { } bool operator==(const StyleAndColour &other) const noexcept { return (style == other.style) && (fore == other.fore); @@ -32,24 +32,24 @@ public: bool under; int fillAlpha; int outlineAlpha; - int attributes; + Scintilla::IndicFlag attributes; XYPOSITION strokeWidth = 1.0f; - Indicator() noexcept : under(false), fillAlpha(30), outlineAlpha(50), attributes(0) { + Indicator() noexcept : under(false), fillAlpha(30), outlineAlpha(50), attributes(Scintilla::IndicFlag::None) { } - Indicator(int style_, ColourRGBA fore_= ColourRGBA(0,0,0), bool under_=false, int fillAlpha_=30, int outlineAlpha_=50) noexcept : - sacNormal(style_, fore_), sacHover(style_, fore_), under(under_), fillAlpha(fillAlpha_), outlineAlpha(outlineAlpha_), attributes(0) { + Indicator(Scintilla::IndicatorStyle style_, ColourRGBA fore_= ColourRGBA(0,0,0), bool under_=false, int fillAlpha_=30, int outlineAlpha_=50) noexcept : + sacNormal(style_, fore_), sacHover(style_, fore_), under(under_), fillAlpha(fillAlpha_), outlineAlpha(outlineAlpha_), attributes(Scintilla::IndicFlag::None) { } void Draw(Surface *surface, const PRectangle &rc, const PRectangle &rcLine, const PRectangle &rcCharacter, State drawState, int value) const; bool IsDynamic() const noexcept { return !(sacNormal == sacHover); } bool OverridesTextFore() const noexcept { - return sacNormal.style == INDIC_TEXTFORE || sacHover.style == INDIC_TEXTFORE; + return sacNormal.style == Scintilla::IndicatorStyle::TextFore || sacHover.style == Scintilla::IndicatorStyle::TextFore; } - int Flags() const noexcept { + Scintilla::IndicFlag Flags() const noexcept { return attributes; } - void SetFlags(int attributes_) noexcept; + void SetFlags(Scintilla::IndicFlag attributes_) noexcept; }; } |