From 5a16cd1123003d6f72d84983292cf96c7fb49d60 Mon Sep 17 00:00:00 2001 From: Eike Rathke Date: Mon, 29 Aug 2022 21:39:19 +0200 Subject: Move input handler function names to ScGlobal static ... as there is only one function list and InputHandlerFunctionNames can be shared instead of each ScInputHandler holding their own copy. Change-Id: Id82b2020f8846456ce7464daa83feb6915792aa2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139012 Reviewed-by: Eike Rathke Tested-by: Jenkins --- sc/inc/global.hxx | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'sc/inc/global.hxx') diff --git a/sc/inc/global.hxx b/sc/inc/global.hxx index 8401ca4c6f7e..3be19f89dcc1 100644 --- a/sc/inc/global.hxx +++ b/sc/inc/global.hxx @@ -20,6 +20,7 @@ #pragma once #include "address.hxx" +#include "typedstrdata.hxx" #include #include #include @@ -455,6 +456,17 @@ struct ScImportParam bool operator== ( const ScImportParam& r ) const; }; +// Formula data replacement character for a pair of parentheses at end of +// function name, to force sorting parentheses before all other characters. +// Collation may treat parentheses differently. +constexpr sal_Unicode cParenthesesReplacement = 0x0001; +struct InputHandlerFunctionNames +{ + ScTypedCaseStrSet maFunctionData; + ScTypedCaseStrSet maFunctionDataPara; + std::set maFunctionChar; +}; + class ScDocShell; class SvxSearchItem; class ScAutoFormat; @@ -523,6 +535,8 @@ class ScGlobal static std::atomic pSharedStringPoolPurge; + static InputHandlerFunctionNames maInputHandlerFunctionNames; + static void InitPPT(); public: @@ -595,6 +609,7 @@ public: static ScFunctionList* GetStarCalcFunctionList(); static ScFunctionMgr* GetStarCalcFunctionMgr(); static void ResetFunctionList(); + static const InputHandlerFunctionNames& GetInputHandlerFunctionNames(); static OUString GetErrorString(FormulaError nErrNumber); static OUString GetLongErrorString(FormulaError nErrNumber); -- cgit