summaryrefslogtreecommitdiff
path: root/include/tools
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.com>2021-11-29 08:28:28 +0100
committerMiklos Vajna <vmiklos@collabora.com>2021-11-29 09:51:16 +0100
commit8662293d17a875f4389ea21be00e768e3de3d048 (patch)
tree6c5d54c67efe3612bcdf63fe6a23f79cacf213f8 /include/tools
parent41cc1d2c0c0c3bfa5ba341311f68df05375859fb (diff)
tools Color: implement MSO-style luminance modulation/offset filter
To be used when a filtered theme color will be applied on the UI, and not at PPTX import time. Change-Id: Ifb56e38e59b529ef436063c407ee156d76a77f9c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/126011 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
Diffstat (limited to 'include/tools')
-rw-r--r--include/tools/color.hxx8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/tools/color.hxx b/include/tools/color.hxx
index a34b55863701..6ab0fa3ba67d 100644
--- a/include/tools/color.hxx
+++ b/include/tools/color.hxx
@@ -335,6 +335,14 @@ public:
**/
void ApplyTintOrShade(sal_Int16 n100thPercent);
+ /**
+ * Apply luminance offset and/or modulation.
+ *
+ * The input values are in percentages (in 100th percents). 100% modulation and 0% offset
+ * results in no change.
+ */
+ void ApplyLumModOff(sal_Int16 nMod, sal_Int16 nOff);
+
/** Inverts color. 1 and 0 are switched.
* Note that the result will be the complementary color.
* For example, if you have red, you will get cyan: FF0000 -> 00FFFF.