summaryrefslogtreecommitdiff
path: root/sc/inc/queryentry.hxx
diff options
context:
space:
mode:
authorSamuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>2021-04-21 09:53:54 +0200
committerSamuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>2021-05-03 09:32:17 +0200
commit5a4bd9bfbdb881368c202bc766f893a5c672621e (patch)
treed3f37369f5085e1f343ebb38c2ed13cd9ed8cc72 /sc/inc/queryentry.hxx
parent95d8eb87eb20351a2e5795fc8c16653c0f58d6b4 (diff)
tdf#76258 Filter by colors
UI/Logic implementation Change-Id: If7b48219caa466d8a3341bdc4e104d696e8988c5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114385 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>
Diffstat (limited to 'sc/inc/queryentry.hxx')
-rw-r--r--sc/inc/queryentry.hxx14
1 files changed, 13 insertions, 1 deletions
diff --git a/sc/inc/queryentry.hxx b/sc/inc/queryentry.hxx
index 9b94f7cdcf6b..f7a7f6896934 100644
--- a/sc/inc/queryentry.hxx
+++ b/sc/inc/queryentry.hxx
@@ -22,6 +22,7 @@
#include "global.hxx"
#include <svl/sharedstring.hxx>
#include <unotools/textsearch.hxx>
+#include <tools/color.hxx>
#include <memory>
#include <vector>
@@ -31,7 +32,15 @@
*/
struct SC_DLLPUBLIC ScQueryEntry
{
- enum QueryType { ByValue, ByString, ByDate, ByEmpty };
+ enum QueryType
+ {
+ ByValue,
+ ByString,
+ ByDate,
+ ByEmpty,
+ ByTextColor,
+ ByBackgroundColor,
+ };
struct SAL_DLLPRIVATE Item
{
@@ -40,6 +49,7 @@ struct SC_DLLPUBLIC ScQueryEntry
svl::SharedString maString;
bool mbMatchEmpty;
bool mbFormattedValue;
+ Color maColor;
Item() : meType(ByValue), mfVal(0.0), mbMatchEmpty(false), mbFormattedValue(false) {}
@@ -68,6 +78,8 @@ struct SC_DLLPUBLIC ScQueryEntry
bool IsQueryByEmpty() const;
void SetQueryByNonEmpty();
bool IsQueryByNonEmpty() const;
+ void SetQueryByTextColor(Color color);
+ void SetQueryByBackgroundColor(Color color);
const Item& GetQueryItem() const { return GetQueryItemImpl(); }
Item& GetQueryItem() { return GetQueryItemImpl(); }
void Clear();