From 50f70a8bb42fc982350731da104b042ae75b1df2 Mon Sep 17 00:00:00 2001 From: Neil Date: Mon, 10 May 2021 14:33:37 +1000 Subject: Add elementBaseColours to hold default or system derived colours. Editor::UpdateBaseElements can be overridden by platform layers to set base colours although they should also do this when they detect changes in system settings. --- src/ViewStyle.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/ViewStyle.h') diff --git a/src/ViewStyle.h b/src/ViewStyle.h index 4118f0daf..a9fe58131 100644 --- a/src/ViewStyle.h +++ b/src/ViewStyle.h @@ -203,6 +203,7 @@ public: using ElementMap = std::map>; ElementMap elementColours; + ElementMap elementBaseColours; std::set elementAllowsTranslucent; WrapAppearance wrap; @@ -243,6 +244,9 @@ public: std::optional ElementColour(int element) const; bool ElementAllowsTranslucent(int element) const; + void ResetElement(int element); + bool ElementIsSet(int element) const; + bool SetElementBase(int element, ColourAlpha colour); bool SetWrapState(int wrapState_) noexcept; bool SetWrapVisualFlags(int wrapVisualFlags_) noexcept; -- cgit v1.2.3