diff options
author | Tomaž Vajngerl <tomaz.vajngerl@collabora.co.uk> | 2023-08-03 10:14:40 +0200 |
---|---|---|
committer | Tomaž Vajngerl <quikee@gmail.com> | 2023-08-15 20:58:13 +0200 |
commit | 9d5a7d9257db78eb3f4d77c39eae1affe877ea6b (patch) | |
tree | e5efa2d17c68055125eb24fe1761c6e77caab4db /xmloff/source/text/XMLComplexColorContext.cxx | |
parent | 918cd8cbf383e0099d80db2e12a1071a0bc4f200 (diff) |
ComplexColor various clean-up and (trivial) refactorings
Don't allow access to member variables of ComplexColor and makes
them private. Needs a lot of changes.
Change "scheme" to "theme" to be more consistent. In LO we usually
call the "theme color" what is usually refered to as "scheme color"
in OOXML, where it is sometimes refered to as "scheme" and other times
as theme color.
Remove ThemeColor class which was replaced with CmplexColor some
time ago.
Remove un-needed includes and un-needed components.
Use isValidThemeColor in many places where we check that the
ComplexColor is of "Theme" type and that ThemeColorType is set to
a valid value.
Change-Id: I325595fa65b8e56a4707e9d22acc6330aac28961
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155359
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'xmloff/source/text/XMLComplexColorContext.cxx')
-rw-r--r-- | xmloff/source/text/XMLComplexColorContext.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/xmloff/source/text/XMLComplexColorContext.cxx b/xmloff/source/text/XMLComplexColorContext.cxx index 7b4e299f95e6..c580b022256a 100644 --- a/xmloff/source/text/XMLComplexColorContext.cxx +++ b/xmloff/source/text/XMLComplexColorContext.cxx @@ -56,7 +56,7 @@ void XMLComplexColorImport::fillAttributes( sal_Int16 nValue = -1; if (SvXMLUnitConverter::convertEnum(nValue, aIter.toView(), pXML_ThemeColor_Enum)) { - mrComplexColor.setSchemeColor(model::convertToThemeColorType(nValue)); + mrComplexColor.setThemeColor(model::convertToThemeColorType(nValue)); } break; } @@ -64,7 +64,7 @@ void XMLComplexColorImport::fillAttributes( { const OUString aValue = aIter.toString(); if (aValue == u"theme") - mrComplexColor.setType(model::ColorType::Scheme); + mrComplexColor.setType(model::ColorType::Theme); // TODO - handle other color types break; } @@ -142,7 +142,7 @@ void XMLPropertyComplexColorContext::endFastElement(sal_Int32 nElement) { if (nElement == mnRootElement) { - if (getComplexColor().getSchemeType() != model::ThemeColorType::Unknown) + if (getComplexColor().getThemeColorType() != model::ThemeColorType::Unknown) { aProp.maValue <<= model::color::createXComplexColor(getComplexColor()); SetInsert(true); |