diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/comphelper/lok.hxx | 7 | ||||
-rw-r--r-- | include/sfx2/lokhelper.hxx | 6 | ||||
-rw-r--r-- | include/sfx2/viewsh.hxx | 6 | ||||
-rw-r--r-- | include/svl/zforlist.hxx | 2 |
4 files changed, 19 insertions, 2 deletions
diff --git a/include/comphelper/lok.hxx b/include/comphelper/lok.hxx index 53ee43f498db..ca875b8df4a2 100644 --- a/include/comphelper/lok.hxx +++ b/include/comphelper/lok.hxx @@ -94,8 +94,11 @@ COMPHELPER_DLLPUBLIC bool isViewIdForVisCursorInvalidation(); /// Set whether clients want viewId in visible cursor invalidation payload. COMPHELPER_DLLPUBLIC void setViewIdForVisCursorInvalidation(bool bViewIdForVisCursorInvalidation); -/// Update the current LOK's language. -COMPHELPER_DLLPUBLIC void setLanguageTag(const OUString& lang, bool bCanonicalize = false); +/// Update the current LOK's locale. +COMPHELPER_DLLPUBLIC void setLocale(const LanguageTag& languageTag); +/// Get the current LOK's locale. +COMPHELPER_DLLPUBLIC const LanguageTag& getLocale(); + /// Update the current LOK's language. COMPHELPER_DLLPUBLIC void setLanguageTag(const LanguageTag& languageTag); /// Get the current LOK's language. diff --git a/include/sfx2/lokhelper.hxx b/include/sfx2/lokhelper.hxx index c05920f548ac..f87432c792b8 100644 --- a/include/sfx2/lokhelper.hxx +++ b/include/sfx2/lokhelper.hxx @@ -54,8 +54,14 @@ public: static std::size_t getViewsCount(); /// Get viewIds of all existing views. static bool getViewIds(int* pArray, size_t nSize); + /// Get the default language that should be used for views + static LanguageTag getDefaultLanguage(); /// Set language of the given view. static void setViewLanguage(int nId, const OUString& rBcp47LanguageTag); + /// Set the default language for views. + static void setDefaultLanguage(const OUString& rBcp47LanguageTag); + /// Set the locale for the given view. + static void setViewLocale(int nId, const OUString& rBcp47LanguageTag); /// Iterate over any view shell, except pThisViewShell, passing it to the f function. template<typename ViewShellType, typename FunctionType> static void forEachOtherView(ViewShellType* pThisViewShell, FunctionType f); diff --git a/include/sfx2/viewsh.hxx b/include/sfx2/viewsh.hxx index d65fae656b16..e81d2db11b7b 100644 --- a/include/sfx2/viewsh.hxx +++ b/include/sfx2/viewsh.hxx @@ -151,6 +151,7 @@ friend class SfxPrinterController; bool bNoNewWindow; bool mbPrinterSettingsModified; LanguageTag maLOKLanguageTag; + LanguageTag maLOKLocale; protected: virtual void Activate(bool IsMDIActivate) override; @@ -346,6 +347,11 @@ public: void SetLOKLanguageTag(const OUString& rBcp47LanguageTag); /// Get the LibreOfficeKit language of this view. const LanguageTag& GetLOKLanguageTag() const { return maLOKLanguageTag; } + + /// Set the LibreOfficeKit locale of this view. + void SetLOKLocale(const OUString& rBcp47LanguageTag); + /// Get the LibreOfficeKit locale of this view. + const LanguageTag& GetLOKLocale() const { return maLOKLocale; } }; diff --git a/include/svl/zforlist.hxx b/include/svl/zforlist.hxx index 22689aa88c3d..e4bf851690f1 100644 --- a/include/svl/zforlist.hxx +++ b/include/svl/zforlist.hxx @@ -730,6 +730,8 @@ public: /// Return the decimal separator matching the given locale / LanguageType. OUString GetLangDecimalSep( LanguageType nLang ) const; + static void resetTheCurrencyTable(); + /// Return a NfCurrencyTable with pointers to <type>NfCurrencyEntry</type> entries static const NfCurrencyTable& GetTheCurrencyTable(); |