diff options
Diffstat (limited to 'include/svx/ColorSets.hxx')
-rw-r--r-- | include/svx/ColorSets.hxx | 32 |
1 files changed, 4 insertions, 28 deletions
diff --git a/include/svx/ColorSets.hxx b/include/svx/ColorSets.hxx index 115b7448a8a0..a5d41cc05a57 100644 --- a/include/svx/ColorSets.hxx +++ b/include/svx/ColorSets.hxx @@ -18,6 +18,7 @@ #include <sal/log.hxx> #include <sal/types.h> #include <svx/svxdllapi.h> +#include <docmodel/theme/ThemeColorType.hxx> #include <tools/color.hxx> typedef struct _xmlTextWriter* xmlTextWriterPtr; @@ -26,31 +27,6 @@ class SdrPage; namespace svx { -/// Offsets into the color list of a theme. -enum class ThemeColorType : sal_Int32 -{ - Unknown = -1, - Dark1 = 0, - Light1 = 1, - Dark2 = 2, - Light2 = 3, - Accent1 = 4, - Accent2 = 5, - Accent3 = 6, - Accent4 = 7, - Accent5 = 8, - Accent6 = 9, - Hyperlink = 10, - FollowedHyperlink = 11, - LAST = FollowedHyperlink -}; - -constexpr ThemeColorType convertToThemeColorType(sal_Int32 nIndex) -{ - if (nIndex < 0 || nIndex > 11) - return ThemeColorType::Unknown; - return static_cast<ThemeColorType>(nIndex); -} class SVXCORE_DLLPUBLIC ColorSet { @@ -67,9 +43,9 @@ public: return maName; } - Color getColor(ThemeColorType nType) const + Color getColor(model::ThemeColorType nType) const { - if (nType == ThemeColorType::Unknown) + if (nType == model::ThemeColorType::Unknown) { SAL_WARN("svx", "ColorSet::getColor with ThemeColorType::Unknown"); return COL_AUTO; @@ -279,7 +255,7 @@ public: std::vector<Color> GetColors() const; - Color GetColor(ThemeColorType eType) const; + Color GetColor(model::ThemeColorType eType) const; }; } // end of namespace svx |