diff options
author | Tomaž Vajngerl <tomaz.vajngerl@collabora.co.uk> | 2023-01-05 13:12:34 +0900 |
---|---|---|
committer | Tomaž Vajngerl <quikee@gmail.com> | 2023-01-13 23:07:22 +0000 |
commit | af8fdba1194e657237f9abc460381a1c4bc49982 (patch) | |
tree | 706c2a25bf0e477a07beaf8047a1f4002c3fe2d5 /svx/source/table | |
parent | c9b0eacae71f111209cb77f14f2693d73e5e8d90 (diff) |
support theme color for lines + oox support + tests
Extended XLineColor to handle model::ThemeColor which then maps
to the newly added LineColorThemeData property.
Extended oox import and export to map the scheme color elements
to and from ThemeColor. Added a new test to check the theme line
color in impress shapes.
Change-Id: I23ecc18c88b5b47608c9110f5681f189d02e2f36
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145071
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'svx/source/table')
-rw-r--r-- | svx/source/table/cell.cxx | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/svx/source/table/cell.cxx b/svx/source/table/cell.cxx index b8ca46ce9921..c39ac6ae7afd 100644 --- a/svx/source/table/cell.cxx +++ b/svx/source/table/cell.cxx @@ -56,6 +56,7 @@ #include <editeng/charrotateitem.hxx> #include <svx/xflbstit.hxx> #include <svx/xflbmtit.hxx> +#include <svx/xlnclit.hxx> #include <svx/svdpool.hxx> #include <svx/xflclit.hxx> #include <comphelper/diagnose_ex.hxx> @@ -1450,7 +1451,6 @@ PropertyState SAL_CALL Cell::getPropertyState( const OUString& PropertyName ) } break; case XATTR_FILLCOLOR: - if (pMap->nMemberId == MID_COLOR_THEME_INDEX) { const XFillColorItem* pColor = rSet.GetItem<XFillColorItem>(pMap->nWID); @@ -1496,6 +1496,16 @@ PropertyState SAL_CALL Cell::getPropertyState( const OUString& PropertyName ) } } break; + case XATTR_LINECOLOR: + if (pMap->nMemberId == MID_COLOR_THEME_REFERENCE) + { + auto const* pColor = rSet.GetItem<XLineColorItem>(pMap->nWID); + if (pColor->GetThemeColor().getType() == model::ThemeColorType::Unknown) + { + eState = PropertyState_DEFAULT_VALUE; + } + } + break; } } } |