summaryrefslogtreecommitdiff
path: root/sc/inc
diff options
context:
space:
mode:
authorBalazs Varga <balazs.varga.extern@allotropia.de>2024-05-07 14:28:05 +0200
committerBalazs Varga <balazs.varga.extern@allotropia.de>2024-05-13 17:20:20 +0200
commitb3a9032378528a691bc97b71a7464712e18c8f4e (patch)
treef62ca67ca111ee2e805fecf2b6a93ae151b049e6 /sc/inc
parent96f74d85983fd693d349d593c4389a8f990fdaaa (diff)
tdf#157657 - sc: add option to make data validity case-sensitive
Add option to check data validity with case sensitive and case insensitive. The default set would remain the original case insensitive mode for data validity. Change-Id: Ic4fe56e2b31b7fc348b742f3b95fb44cd35bc49d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167280 Tested-by: Jenkins Reviewed-by: Balazs Varga <balazs.varga.extern@allotropia.de>
Diffstat (limited to 'sc/inc')
-rw-r--r--sc/inc/conditio.hxx6
-rw-r--r--sc/inc/fmtuno.hxx1
-rw-r--r--sc/inc/sc.hrc19
3 files changed, 17 insertions, 9 deletions
diff --git a/sc/inc/conditio.hxx b/sc/inc/conditio.hxx
index 430858122a75..24c42ffbe703 100644
--- a/sc/inc/conditio.hxx
+++ b/sc/inc/conditio.hxx
@@ -56,6 +56,7 @@ struct RefUpdateMoveTabContext;
// nOptions Flags
#define SC_COND_NOBLANKS 1
+#define SC_COND_CASESENS 2
enum class ScConditionMode
{
@@ -369,8 +370,13 @@ public:
ScConditionMode GetOperation() const { return eOp; }
void SetOperation(ScConditionMode eMode);
+
bool IsIgnoreBlank() const { return ( nOptions & SC_COND_NOBLANKS ) == 0; }
SC_DLLPUBLIC void SetIgnoreBlank(bool bSet);
+
+ bool IsCaseSensitive() const { return ( nOptions & SC_COND_CASESENS ) != 0; }
+ SC_DLLPUBLIC void SetCaseSensitive(bool bSet);
+
const OUString& GetSrcString() const { return aSrcString; }
const ScAddress& GetSrcPos() const { return aSrcPos; }
diff --git a/sc/inc/fmtuno.hxx b/sc/inc/fmtuno.hxx
index 3796e820c075..91e3b66db020 100644
--- a/sc/inc/fmtuno.hxx
+++ b/sc/inc/fmtuno.hxx
@@ -168,6 +168,7 @@ private:
OUString aPosString; // formula position as text
sal_uInt16 nValMode; // enum ScValidationMode
bool bIgnoreBlank;
+ bool bCaseSensitive;
sal_Int16 nShowList;
bool bShowInput;
OUString aInputTitle;
diff --git a/sc/inc/sc.hrc b/sc/inc/sc.hrc
index 54d4c0b5a0e2..9ef248660d7e 100644
--- a/sc/inc/sc.hrc
+++ b/sc/inc/sc.hrc
@@ -576,15 +576,16 @@ static_assert(SID_PREVIEW_END < SID_KEYFUNC_START, "calc slots ids trampling inf
#define FID_VALID_VALUE1 TypedWhichId<SfxStringItem>(SID_NEW_SLOTS+62)
#define FID_VALID_VALUE2 TypedWhichId<SfxStringItem>(SID_NEW_SLOTS+63)
#define FID_VALID_BLANK TypedWhichId<SfxBoolItem>(SID_NEW_SLOTS+64)
-#define FID_VALID_SHOWHELP TypedWhichId<SfxBoolItem>(SID_NEW_SLOTS+65)
-#define FID_VALID_HELPTITLE TypedWhichId<SfxStringItem>(SID_NEW_SLOTS+66)
-#define FID_VALID_HELPTEXT TypedWhichId<SfxStringItem>(SID_NEW_SLOTS+67)
-#define FID_VALID_SHOWERR TypedWhichId<SfxBoolItem>(SID_NEW_SLOTS+68)
-#define FID_VALID_ERRSTYLE TypedWhichId<SfxUInt16Item>(SID_NEW_SLOTS+69)
-#define FID_VALID_ERRTITLE TypedWhichId<SfxStringItem>(SID_NEW_SLOTS+70)
-#define FID_VALID_ERRTEXT TypedWhichId<SfxStringItem>(SID_NEW_SLOTS+71)
-
-#define SID_REFRESH_DBAREA (SID_NEW_SLOTS+72)
+#define FID_VALID_CASESENS TypedWhichId<SfxBoolItem>(SID_NEW_SLOTS+65)
+#define FID_VALID_SHOWHELP TypedWhichId<SfxBoolItem>(SID_NEW_SLOTS+66)
+#define FID_VALID_HELPTITLE TypedWhichId<SfxStringItem>(SID_NEW_SLOTS+67)
+#define FID_VALID_HELPTEXT TypedWhichId<SfxStringItem>(SID_NEW_SLOTS+68)
+#define FID_VALID_SHOWERR TypedWhichId<SfxBoolItem>(SID_NEW_SLOTS+69)
+#define FID_VALID_ERRSTYLE TypedWhichId<SfxUInt16Item>(SID_NEW_SLOTS+70)
+#define FID_VALID_ERRTITLE TypedWhichId<SfxStringItem>(SID_NEW_SLOTS+71)
+#define FID_VALID_ERRTEXT TypedWhichId<SfxStringItem>(SID_NEW_SLOTS+72)
+
+#define SID_REFRESH_DBAREA (SID_NEW_SLOTS+73)
#define FID_FOCUS_POSWND (SID_NEW_SLOTS+74)