LibreOffice Module svl (master) 1
|
#include <numformat.hxx>
Classes | |
struct | InputScannerPrivateAccess |
Public Member Functions | |
SvNumberFormatter (const css::uno::Reference< css::uno::XComponentContext > &rxContext, LanguageType eLang) | |
Preferred ctor with service manager and language/country enum. More... | |
~SvNumberFormatter () | |
void | SetColorLink (const Link< sal_uInt16, Color * > &rColorTableCallBack) |
Set CallBack to ColorTable. More... | |
Color * | GetUserDefColor (sal_uInt16 nIndex) |
Do the CallBack to ColorTable. More... | |
void | ChangeIntl (LanguageType eLnge) |
Change language/country, also input and format scanner. More... | |
void | ChangeNullDate (sal_uInt16 nDay, sal_uInt16 nMonth, sal_Int16 nYear) |
Change the reference null date. More... | |
void | ChangeStandardPrec (short nPrec) |
Change standard precision. More... | |
void | SetNoZero (bool bNZ) |
Set zero value suppression. More... | |
LanguageType | GetLanguage () const |
The language with which the formatter was initialized (system setting), NOT the current language after a ChangeIntl() More... | |
SvNumberFormatTable & | GetEntryTable (SvNumFormatType eType, sal_uInt32 &FIndex, LanguageType eLnge) |
Get table of formats of a specific type of a locale. More... | |
SvNumberFormatTable & | ChangeCL (SvNumFormatType eType, sal_uInt32 &FIndex, LanguageType eLnge) |
Get table of formats of a specific type of a language/country. More... | |
SvNumberFormatTable & | GetFirstEntryTable (SvNumFormatType &eType, sal_uInt32 &FIndex, LanguageType &rLnge) |
Get table of formats of the same type as FIndex; eType and rLnge are set accordingly. More... | |
void | DeleteEntry (sal_uInt32 nKey) |
Delete an entry including the format it is referring to. More... | |
bool | PutEntry (OUString &rString, sal_Int32 &nCheckPos, SvNumFormatType &nType, sal_uInt32 &nKey, LanguageType eLnge=LANGUAGE_DONTKNOW, bool bReplaceBooleanEquivalent=true) |
Create new entry of a format code string for language/country. More... | |
bool | PutandConvertEntry (OUString &rString, sal_Int32 &nCheckPos, SvNumFormatType &nType, sal_uInt32 &nKey, LanguageType eLnge, LanguageType eNewLnge, bool bConvertDateOrder, bool bReplaceBooleanEquivalent=true) |
Same as <method>PutEntry</method> but the format code string is considered to be of language/country eLnge and is converted to language/country eNewLnge. More... | |
bool | PutandConvertEntrySystem (OUString &rString, sal_Int32 &nCheckPos, SvNumFormatType &nType, sal_uInt32 &nKey, LanguageType eLnge, LanguageType eNewLnge) |
Same as <method>PutandConvertEntry</method> but the format code string is considered to be of the System language/country eLnge and is converted to another System language/country eNewLnge. More... | |
sal_uInt32 | GetIndexPuttingAndConverting (OUString &rString, LanguageType eLnge, LanguageType eSysLnge, SvNumFormatType &rType, bool &rNewInserted, sal_Int32 &rCheckPos) |
Similar to <method>PutEntry</method> and <method>PutandConvertEntry</method> or <method>PutandConvertEntrySystem</method>, the format code string passed is considered to be of language/country eLnge. More... | |
OUString | GenerateFormat (sal_uInt32 nIndex, LanguageType eLnge=LANGUAGE_DONTKNOW, bool bThousand=false, bool IsRed=false, sal_uInt16 nPrecision=0, sal_uInt16 nLeadingCnt=1) |
Create a format code string using format nIndex as a template and applying other settings (passed from the dialog) More... | |
bool | IsNumberFormat (const OUString &sString, sal_uInt32 &F_Index, double &fOutNumber, SvNumInputOptions eInputOptions=SvNumInputOptions::NONE) |
Analyze an input string. More... | |
void | GetOutputString (const double &fOutNumber, sal_uInt32 nFIndex, OUString &sOutString, const Color **ppColor, bool bUseStarFormat=false) |
Format a number according to a format index, return string and color. More... | |
void | GetOutputString (const OUString &sString, sal_uInt32 nFIndex, OUString &sOutString, const Color **ppColor, bool bUseStarFormat=false) |
Format a string according to a format index, return string and color. More... | |
void | GetInputLineString (const double &fOutNumber, sal_uInt32 nFIndex, OUString &rOutString, bool bFiltering=false, bool bForceSystemLocale=false) |
Format a number according to the standard default format matching the given format index. More... | |
bool | GetPreviewString (const OUString &sFormatString, double fPreviewNumber, OUString &sOutString, const Color **ppColor, LanguageType eLnge, bool bUseStarFormat=false) |
Format a number according to a format code string to be scanned. More... | |
bool | GetPreviewStringGuess (const OUString &sFormatString, double fPreviewNumber, OUString &sOutString, const Color **ppColor, LanguageType eLnge=LANGUAGE_DONTKNOW) |
Same as <method>GetPreviewString</method> but the format code string may be either language/country eLnge or en_US english US. More... | |
bool | GetPreviewString (const OUString &sFormatString, const OUString &sPreviewString, OUString &sOutString, const Color **ppColor, LanguageType eLnge=LANGUAGE_DONTKNOW) |
Format a string according to a format code string to be scanned. More... | |
sal_uInt32 | TestNewString (const OUString &sFormatString, LanguageType eLnge=LANGUAGE_DONTKNOW) |
Test whether the format code string is already present in container. More... | |
bool | IsTextFormat (sal_uInt32 nFIndex) const |
Whether format index nFIndex is of type text or not. More... | |
bool | IsNatNum12 (sal_uInt32 nFIndex) const |
Whether format index nFIndex has NatNum12 modifier. More... | |
void | GetFormatSpecialInfo (sal_uInt32 nFormat, bool &bThousand, bool &IsRed, sal_uInt16 &nPrecision, sal_uInt16 &nLeadingCnt) |
Get additional info of a format index, e.g. for dialog box. More... | |
sal_uInt16 | GetFormatPrecision (sal_uInt32 nFormat) const |
Count of decimals. More... | |
sal_uInt16 | GetFormatIntegerDigits (sal_uInt32 nFormat) const |
Count of integer digits. More... | |
sal_uInt32 | GetFormatSpecialInfo (const OUString &, bool &bThousand, bool &IsRed, sal_uInt16 &nPrecision, sal_uInt16 &nLeadingCnt, LanguageType eLnge=LANGUAGE_DONTKNOW) |
Get additional info of a format code string, e.g. More... | |
OUString | GetCalcCellReturn (sal_uInt32 nFormat) const |
Get return string for Calc CELL() function, "G", "D1", ... More... | |
bool | IsUserDefined (sal_uInt32 F_Index) const |
bool | IsUserDefined (std::u16string_view sStr, LanguageType eLnge=LANGUAGE_DONTKNOW) |
Check if format code string may be deleted by user. More... | |
sal_uInt32 | GetEntryKey (std::u16string_view sStr, LanguageType eLnge=LANGUAGE_DONTKNOW) |
Return the format index of the format code string for language/country, or NUMBERFORMAT_ENTRY_NOT_FOUND. More... | |
const SvNumberformat * | GetEntry (sal_uInt32 nKey) const |
Return the format for a format index. More... | |
const SvNumberformat * | GetSubstitutedEntry (sal_uInt32 nKey, sal_uInt32 &o_rNewKey) const |
Obtain substituted GetFormatEntry(), i.e. system formats. More... | |
sal_uInt32 | GetStandardIndex (LanguageType eLnge=LANGUAGE_DONTKNOW) |
Return the format index of the standard default number format for language/country. More... | |
sal_uInt32 | GetStandardFormat (SvNumFormatType eType, LanguageType eLnge=LANGUAGE_DONTKNOW) |
Return the format index of the default format of a type for language/country. More... | |
sal_uInt32 | GetStandardFormat (sal_uInt32 nFIndex, SvNumFormatType eType, LanguageType eLnge) |
Return the format index of the default format of a type for language/country. More... | |
sal_uInt32 | GetStandardFormat (double fNumber, sal_uInt32 nFIndex, SvNumFormatType eType, LanguageType eLnge) |
Return the format index of the default format of a type for language/country. More... | |
bool | IsSpecialStandardFormat (sal_uInt32 nFIndex, LanguageType eLnge) |
Whether nFIndex is a special builtin format. More... | |
sal_uInt32 | GetTimeFormat (double fNumber, LanguageType eLnge, bool bForceDuration) |
Return a time format that best matches fNumber. More... | |
sal_uInt32 | GuessDateTimeFormat (SvNumFormatType &rType, double fNumber, LanguageType eLnge) |
Return a format and type that best matches the value of fNumber if fNumber is assumed to be a date, time or datetime value, but unknown which. More... | |
sal_uInt32 | GetEditFormat (double fNumber, sal_uInt32 nFIndex, SvNumFormatType eType, SvNumberformat const *pFormat, LanguageType eForLocale=LANGUAGE_DONTKNOW) |
Return the corresponding edit format of a format. More... | |
const Date & | GetNullDate () const |
Return the reference date. More... | |
sal_uInt16 | GetStandardPrec () const |
Return the standard decimal precision. More... | |
bool | GetNoZero () const |
Return whether zero suppression is switched on. More... | |
SvNumFormatType | GetType (sal_uInt32 nFIndex) const |
Get the type of a format (or css::util::NumberFormat::UNDEFINED if no entry), but with css::util::NumberFormat::DEFINED masked out. More... | |
void | ClearMergeTable () |
As the name says. More... | |
SvNumberFormatterIndexTable * | MergeFormatter (SvNumberFormatter &rNewTable) |
Merge in all new entries from rNewTable and return a table of resulting new format indices. More... | |
bool | HasMergeFormatTable () const |
Whether a merge table is present or not. More... | |
sal_uInt32 | GetMergeFormatIndex (sal_uInt32 nOldFmt) const |
Return the new format index for an old format index, if a merge table exists. More... | |
SvNumberFormatterMergeMap | ConvertMergeTableToMap () |
Convert the ugly old tools' Table type bloated with new'ed sal_uInt32 entries merge table to ::std::map with old index key and new index key. More... | |
sal_uInt32 | GetFormatForLanguageIfBuiltIn (sal_uInt32 nFormat, LanguageType eLnge=LANGUAGE_DONTKNOW) |
Return the format index of a builtin format for a specific language/country. More... | |
sal_uInt32 | GetFormatIndex (NfIndexTableOffset, LanguageType eLnge=LANGUAGE_DONTKNOW) |
Return the format index for a builtin format of a specific language. More... | |
NfIndexTableOffset | GetIndexTableOffset (sal_uInt32 nFormat) const |
Return enum index of a format index of a builtin format, NF_INDEX_TABLE_ENTRIES if it's not a builtin format. More... | |
void | SetEvalDateFormat (NfEvalDateFormat eEDF) |
Set evaluation type and order of input date strings. More... | |
NfEvalDateFormat | GetEvalDateFormat () const |
void | SetYear2000 (sal_uInt16 nVal) |
Set TwoDigitYearStart, how the input string scanner handles a two digit year. More... | |
sal_uInt16 | GetYear2000 () const |
sal_uInt16 | ExpandTwoDigitYear (sal_uInt16 nYear) const |
OUString | GetFormatDecimalSep (sal_uInt32 nFormat) const |
Return the decimal separator matching the locale of the given format. More... | |
OUString | GetLangDecimalSep (LanguageType nLang) const |
Return the decimal separator matching the given locale / LanguageType. More... | |
sal_uInt16 | GetCurrencyFormatStrings (NfWSStringsDtor &, const NfCurrencyEntry &, bool bBank) const |
Get all standard formats for a specific currency, formats are appended to the NfWSStringsDtor list. More... | |
bool | GetNewCurrencySymbolString (sal_uInt32 nFormat, OUString &rSymbol, const NfCurrencyEntry **ppEntry, bool *pBank=nullptr) const |
Whether nFormat is of type css::util::NumberFormat::CURRENCY and the format code contains a new SYMBOLTYPE_CURRENCY and if so which one [$xxx-nnn]. More... | |
void | GetCompatibilityCurrency (OUString &rSymbol, OUString &rAbbrev) const |
Get compatibility ("automatic" old style) currency from I18N locale data. More... | |
void | GetUsedLanguages (std::vector< LanguageType > &rList) |
Fill rList with the language/country codes that have been allocated. More... | |
void | FillKeywordTable (NfKeywordTable &rKeywords, LanguageType eLang) |
Fill a NfKeywordIndex table with keywords of a language/country. More... | |
void | FillKeywordTableForExcel (NfKeywordTable &rKeywords) |
Fill a NfKeywordIndex table with keywords usable in Excel export with GetFormatStringForExcel() or SvNumberformat::GetMappedFormatstring() More... | |
OUString | GetFormatStringForExcel (sal_uInt32 nKey, const NfKeywordTable &rKeywords, SvNumberFormatter &rTempFormatter) const |
Return a format code string suitable for Excel export. More... | |
OUString | GetKeyword (LanguageType eLnge, sal_uInt16 nIndex) |
Return a keyword for a language/country and NfKeywordIndex for XML import, to generate number format strings. More... | |
OUString | GetStandardName (LanguageType eLnge) |
Return the GENERAL keyword in proper case ("General") for a language/country, used in XML import. More... | |
const NfKeywordTable & | GetKeywords (sal_uInt32 nKey) |
Obtain NfKeywordTable used with a format, possibly localized. More... | |
const NfKeywordTable & | GetEnglishKeywords () const |
Access for unit tests. More... | |
const std::vector< Color > & | GetStandardColors () const |
Access for unit tests. More... | |
size_t | GetMaxDefaultColors () const |
Access for unit tests. More... | |
OnDemandLocaleDataWrapper & | GetOnDemandLocaleDataWrapper (const InputScannerPrivateAccess &) |
Access for input scanner to temporarily (!) switch locales. More... | |
void | ResetDefaultSystemCurrency () |
void | InvalidateDateAcceptancePatterns () |
void | ReplaceSystemCL (LanguageType eOldLanguage) |
const css::uno::Reference< css::uno::XComponentContext > & | GetComponentContext () const |
const ImpSvNumberformatScan * | GetFormatScanner () const |
The following method is not to be used from outside but must be public for the InputScanner. More... | |
const LanguageTag & | GetLanguageTag () const |
The following methods are not to be used from outside but must be public for the InputScanner and FormatScanner. More... | |
const ::utl::TransliterationWrapper * | GetTransliteration () const |
const CharClass * | GetCharClass () const |
const LocaleDataWrapper * | GetLocaleData () const |
CalendarWrapper * | GetCalendar () const |
const NativeNumberWrapper * | GetNatNum () const |
const OUString & | GetNumDecimalSep () const |
const OUString & | GetNumDecimalSepAlt () const |
const OUString & | GetNumThousandSep () const |
const OUString & | GetDateSep () const |
bool | IsDecimalSep (std::u16string_view rStr) const |
Static Public Member Functions | |
static bool | IsCompatible (SvNumFormatType eOldType, SvNumFormatType eNewType) |
static sal_uInt16 | GetYear2000Default () |
static sal_uInt16 | ExpandTwoDigitYear (sal_uInt16 nYear, sal_uInt16 nTwoDigitYearStart) |
static void | resetTheCurrencyTable () |
static const NfCurrencyTable & | GetTheCurrencyTable () |
Return a NfCurrencyTable with pointers to <type>NfCurrencyEntry</type> entries. More... | |
static const NfCurrencyEntry * | MatchSystemCurrency () |
Searches, according to the default locale currency, an entry of the CurrencyTable which is <bold>not</bold> the first (LANGUAGE_SYSTEM) entry. More... | |
static const NfCurrencyEntry & | GetCurrencyEntry (LanguageType) |
Return a NfCurrencyEntry matching a language/country. More... | |
static const NfCurrencyEntry * | GetCurrencyEntry (std::u16string_view rAbbrev, LanguageType eLang) |
Return a NfCurrencyEntry pointer matching a language/country and currency abbreviation (AKA banking symbol). More... | |
static const NfCurrencyEntry * | GetLegacyOnlyCurrencyEntry (std::u16string_view rSymbol, std::u16string_view rAbbrev) |
Return a NfCurrencyEntry pointer matching the symbol combination of a LegacyOnly currency. More... | |
static void | SetDefaultSystemCurrency (std::u16string_view rAbbrev, LanguageType eLang) |
Set the default system currency. More... | |
static const NfCurrencyEntry * | GetCurrencyEntry (bool &bFoundBank, std::u16string_view rSymbol, std::u16string_view rExtension, LanguageType eFormatLanguage, bool bOnlyStringLanguage=false) |
Look up the corresponding NfCurrencyEntry matching rSymbol (may be CurrencySymbol or CurrencyAbbreviation) and possibly a rExtension (being yyy of [$xxx-yyy]) or a given language/country value. More... | |
static bool | IsLocaleInstalled (LanguageType eLang) |
Check if a specific locale has supported locale data. More... | |
Static Public Attributes | |
static const sal_uInt16 | UNLIMITED_PRECISION = ::std::numeric_limits<sal_uInt16>::max() |
We can't technically have an "infinite" value, so we use an arbitrary upper precision threshold to represent the "unlimited" precision. More... | |
static const sal_uInt16 | INPUTSTRING_PRECISION = ::std::numeric_limits<sal_uInt16>::max()-1 |
Precision suitable for numbers displayed in input bar, for instance Calc's formula input bar. More... | |
Private Types | |
typedef std::map< sal_uInt32, sal_uInt32 > | DefaultFormatKeysMap |
Private Member Functions | |
SVL_DLLPRIVATE void | ImpConstruct (LanguageType eLang) |
SVL_DLLPRIVATE void | ImpGenerateFormats (sal_uInt32 CLOffset, bool bNoAdditionalFormats) |
SVL_DLLPRIVATE void | ImpGenerateAdditionalFormats (sal_uInt32 CLOffset, css::uno::Reference< css::i18n::XNumberFormatCode > const &rNumberFormatCode, bool bAfterChangingSystemCL) |
SVL_DLLPRIVATE SvNumberformat * | ImpInsertFormat (const css::i18n::NumberFormatCode &rCode, sal_uInt32 nPos, bool bAfterChangingSystemCL=false, sal_Int16 nOrgIndex=0) |
SVL_DLLPRIVATE sal_uInt32 | ImpGetCLOffset (LanguageType eLnge) const |
SVL_DLLPRIVATE sal_uInt32 | ImpIsEntry (std::u16string_view rString, sal_uInt32 CLOffset, LanguageType eLnge) |
SVL_DLLPRIVATE sal_uInt32 | ImpGenerateCL (LanguageType eLnge) |
SVL_DLLPRIVATE sal_uInt32 | ImpGetDefaultSystemCurrencyFormat () |
SVL_DLLPRIVATE sal_uInt32 | ImpGetDefaultCurrencyFormat () |
SVL_DLLPRIVATE sal_uInt32 | ImpGetDefaultFormat (SvNumFormatType nType) |
SVL_DLLPRIVATE sal_Int32 | ImpGetFormatCodeIndex (css::uno::Sequence< css::i18n::NumberFormatCode > &rSeq, const NfIndexTableOffset nTabOff) |
SVL_DLLPRIVATE void | ImpAdjustFormatCodeDefault (css::i18n::NumberFormatCode *pFormatArr, sal_Int32 nCount) |
SVL_DLLPRIVATE SvNumberformat * | GetFormatEntry (sal_uInt32 nKey) |
SVL_DLLPRIVATE const SvNumberformat * | GetFormatEntry (sal_uInt32 nKey) const |
DECL_DLLPRIVATE_STATIC_LINK (SvNumberFormatter, CurrencyChangeLink, LinkParamNone *, void) | |
sal_Int32 | ImpPosToken (const OUStringBuffer &sFormat, sal_Unicode token, sal_Int32 nStartPos=0) const |
SvNumberformat * | ImpSubstituteEntry (SvNumberformat *pFormat, sal_uInt32 *o_pRealKey=nullptr) |
::osl::Mutex & | GetInstanceMutex () const |
Static Private Member Functions | |
static SVL_DLLPRIVATE SvNumberFormatterRegistry_Impl & | GetFormatterRegistry () |
static SVL_DLLPRIVATE void | ImpInitCurrencyTable () |
static bool | ImpLookupCurrencyEntryLoopBody (const NfCurrencyEntry *&pFoundEntry, bool &bFoundBank, const NfCurrencyEntry *pData, sal_uInt16 nPos, std::u16string_view rSymbol) |
::osl::Mutex & | GetGlobalMutex () |
Private Attributes | |
mutable::osl::Mutex | m_aMutex |
css::uno::Reference< css::uno::XComponentContext > | m_xContext |
LanguageTag | maLanguageTag |
std::map< sal_uInt32, std::unique_ptr< SvNumberformat > > | aFTable |
DefaultFormatKeysMap | aDefaultFormatKeys |
std::unique_ptr< SvNumberFormatTable > | pFormatTable |
std::unique_ptr< SvNumberFormatterIndexTable > | pMergeTable |
OnDemandCharClass | xCharClass |
OnDemandLocaleDataWrapper | xLocaleData |
OnDemandTransliterationWrapper | xTransliteration |
OnDemandCalendarWrapper | xCalendar |
OnDemandNativeNumberWrapper | xNatNum |
std::unique_ptr< ImpSvNumberInputScan > | pStringScanner |
std::unique_ptr< ImpSvNumberformatScan > | pFormatScanner |
Link< sal_uInt16, Color * > | aColorLink |
sal_uInt32 | MaxCLOffset |
sal_uInt32 | nDefaultSystemCurrencyFormat |
LanguageType | IniLnge |
LanguageType | ActLnge |
NfEvalDateFormat | eEvalDateFormat |
bool | bNoZero |
OUString | aDecimalSep |
OUString | aDecimalSepAlt |
OUString | aThousandSep |
OUString | aDateSep |
Static Private Attributes | |
static SVL_DLLPRIVATE volatile bool | bCurrencyTableInitialized = false |
static SVL_DLLPRIVATE sal_uInt16 | nSystemCurrencyPosition = 0 |
static SVL_DLLPRIVATE SvNumberFormatterRegistry_Impl * | pFormatterRegistry = nullptr |
Friends | |
class | SvNumberFormatterRegistry_Impl |
Definition at line 39 of file numformat.hxx.
|
private |
Definition at line 579 of file numformat.hxx.
SvNumberFormatter::SvNumberFormatter | ( | const css::uno::Reference< css::uno::XComponentContext > & | rxContext, |
LanguageType | eLang | ||
) |
Preferred ctor with service manager and language/country enum.
Definition at line 275 of file zforlist.cxx.
References ImpConstruct(), m_xContext, and maLanguageTag.
SvNumberFormatter::~SvNumberFormatter | ( | ) |
Definition at line 283 of file zforlist.cxx.
References aFTable, ClearMergeTable(), SvNumberFormatterRegistry_Impl::Count(), GetGlobalMutex(), pFormatterRegistry, and SvNumberFormatterRegistry_Impl::Remove().
SvNumberFormatTable & SvNumberFormatter::ChangeCL | ( | SvNumFormatType | eType, |
sal_uInt32 & | FIndex, | ||
LanguageType | eLnge | ||
) |
Get table of formats of a specific type of a language/country.
FIndex returns the default format of that type. If the language/country was never touched before new entries are generated
Definition at line 1134 of file zforlist.cxx.
References ActLnge, eType, GetEntryTable(), GetInstanceMutex(), and ImpGenerateCL().
Referenced by SvNumberFormatsObj::queryKeys().
void SvNumberFormatter::ChangeIntl | ( | LanguageType | eLnge | ) |
Change language/country, also input and format scanner.
Definition at line 338 of file zforlist.cxx.
References ActLnge, aDateSep, aDecimalSep, aDecimalSepAlt, aThousandSep, OnDemandCalendarWrapper::changeLocale(), OnDemandCharClass::changeLocale(), OnDemandLocaleDataWrapper::changeLocale(), OnDemandTransliterationWrapper::changeLocale(), LocaleDataWrapper::getDateSep(), GetInstanceMutex(), LanguageTag::getLocale(), GetLocaleData(), LocaleDataWrapper::getNumDecimalSep(), LocaleDataWrapper::getNumDecimalSepAlt(), LocaleDataWrapper::getNumThousandSep(), m_xContext, maLanguageTag, pFormatScanner, pStringScanner, LanguageTag::reset(), xCalendar, xCharClass, xLocaleData, and xTransliteration.
Referenced by FillKeywordTable(), ImpSvNumberformatScan::FinalScan(), GetEntryTable(), GetFirstEntryTable(), GetFormatSpecialInfo(), GetFormatStringForExcel(), GetInputLineString(), GetKeyword(), GetKeywords(), GetOutputString(), GetPreviewString(), GetPreviewStringGuess(), GetStandardName(), ImpGenerateCL(), IsNumberFormat(), PutandConvertEntry(), PutEntry(), ReplaceSystemCL(), SvNumberformat::SvNumberformat(), and TestNewString().
void SvNumberFormatter::ChangeNullDate | ( | sal_uInt16 | nDay, |
sal_uInt16 | nMonth, | ||
sal_Int16 | nYear | ||
) |
Change the reference null date.
Definition at line 406 of file zforlist.cxx.
References GetInstanceMutex(), pFormatScanner, and pStringScanner.
Referenced by SvNumberFormatSettingsObj::setPropertyValue().
void SvNumberFormatter::ChangeStandardPrec | ( | short | nPrec | ) |
Change standard precision.
Definition at line 421 of file zforlist.cxx.
References GetInstanceMutex(), and pFormatScanner.
Referenced by GetInputLineString(), and SvNumberFormatSettingsObj::setPropertyValue().
void SvNumberFormatter::ClearMergeTable | ( | ) |
As the name says.
Definition at line 3446 of file zforlist.cxx.
References GetInstanceMutex(), and pMergeTable.
Referenced by ConvertMergeTableToMap(), MergeFormatter(), and ~SvNumberFormatter().
SvNumberFormatterMergeMap SvNumberFormatter::ConvertMergeTableToMap | ( | ) |
Convert the ugly old tools' Table type bloated with new'ed sal_uInt32 entries merge table to ::std::map with old index key and new index key.
@ATTENTION! Also clears the old table using ClearMergeTable()
Definition at line 3530 of file zforlist.cxx.
References aMap, ClearMergeTable(), GetInstanceMutex(), HasMergeFormatTable(), and pMergeTable.
|
private |
void SvNumberFormatter::DeleteEntry | ( | sal_uInt32 | nKey | ) |
Delete an entry including the format it is referring to.
Definition at line 793 of file zforlist.cxx.
References aFTable, and GetInstanceMutex().
Referenced by GetIndexPuttingAndConverting(), and SvNumberFormatsObj::removeByKey().
sal_uInt16 SvNumberFormatter::ExpandTwoDigitYear | ( | sal_uInt16 | nYear | ) | const |
Definition at line 3631 of file zforlist.cxx.
References ExpandTwoDigitYear(), and pStringScanner.
Referenced by ExpandTwoDigitYear(), and ImpSvNumberInputScan::ImplGetYear().
|
static |
Definition at line 4433 of file zforlist.cxx.
void SvNumberFormatter::FillKeywordTable | ( | NfKeywordTable & | rKeywords, |
LanguageType | eLang | ||
) |
Fill a NfKeywordIndex table with keywords of a language/country.
Definition at line 817 of file zforlist.cxx.
References ChangeIntl(), GetInstanceMutex(), i, NF_KEYWORD_ENTRIES_COUNT, and pFormatScanner.
Referenced by FillKeywordTableForExcel().
void SvNumberFormatter::FillKeywordTableForExcel | ( | NfKeywordTable & | rKeywords | ) |
Fill a NfKeywordIndex table with keywords usable in Excel export with GetFormatStringForExcel() or SvNumberformat::GetMappedFormatstring()
Definition at line 830 of file zforlist.cxx.
References FillKeywordTable(), GetInstanceMutex(), GetStandardName(), LANGUAGE_ENGLISH_US, NF_KEY_D, NF_KEY_DD, NF_KEY_DDD, NF_KEY_DDDD, NF_KEY_EC, NF_KEY_EEC, NF_KEY_G, NF_KEY_GENERAL, NF_KEY_GG, NF_KEY_GGG, NF_KEY_H, NF_KEY_HH, NF_KEY_M, NF_KEY_MI, NF_KEY_MM, NF_KEY_MMI, NF_KEY_MMM, NF_KEY_MMMM, NF_KEY_MMMMM, NF_KEY_NN, NF_KEY_NNN, NF_KEY_NNNN, NF_KEY_R, NF_KEY_RR, NF_KEY_S, NF_KEY_SS, NF_KEY_THAI_T, NF_KEY_YY, and NF_KEY_YYYY.
OUString SvNumberFormatter::GenerateFormat | ( | sal_uInt32 | nIndex, |
LanguageType | eLnge = LANGUAGE_DONTKNOW , |
||
bool | bThousand = false , |
||
bool | IsRed = false , |
||
sal_uInt16 | nPrecision = 0 , |
||
sal_uInt16 | nLeadingCnt = 1 |
||
) |
Create a format code string using format nIndex as a template and applying other settings (passed from the dialog)
Definition at line 3158 of file zforlist.cxx.
References utl::DigitGroupingIterator::advance(), CURRENCY, eType, FRACTION, utl::DigitGroupingIterator::get(), GetCompatibilityCurrency(), LocaleDataWrapper::getCurrNegativeFormat(), LocaleDataWrapper::getCurrPositiveFormat(), LocaleDataWrapper::getDigitGrouping(), GetFormatEntry(), SvNumberformat::GetFormatstring(), SvNumberformat::GetFormatStringForTimePrecision(), GetInstanceMutex(), SvNumberformat::GetIntegerFractionDelimiterString(), SvNumberformat::GetMaskedType(), SvNumberformat::GetNatNumModifierString(), GetNewCurrencySymbolString(), GetNumDecimalSep(), SvNumberformat::GetNumeratorString(), SvNumberformat::GetNumForString(), GetNumThousandSep(), SvNumberformat::GetPercentString(), utl::DigitGroupingIterator::getPos(), SvNumberformat::HasPositiveBracketPlaceholder(), i, ImpGenerateCL(), ImpPosToken(), IniLnge, SvNumberformat::IsNegativeInBracket(), LANGUAGE_DONTKNOW, nIndex, padToLength(), comphelper::string::padToLength(), PERCENT, pFormatScanner, SCIENTIFIC, TIME, UNDEFINED, and xLocaleData.
Referenced by SvNumberFormatsObj::generateFormat().
OUString SvNumberFormatter::GetCalcCellReturn | ( | sal_uInt32 | nFormat | ) | const |
Get return string for Calc CELL() function, "G", "D1", ...
Definition at line 2294 of file zforlist.cxx.
References aStr, CURRENCY, SvNumberformat::GetColor(), GetFormatEntry(), SvNumberformat::GetFormatSpecialInfo(), SvNumberformat::GetFormatstring(), GetIndexTableOffset(), GetInstanceMutex(), SvNumberformat::GetMaskedType(), NF_DATE_DIN_DMMMMYYYY, NF_DATE_DIN_DMMMYYYY, NF_DATE_DIN_MMDD, NF_DATE_SYS_DDMMM, NF_DATE_SYS_DDMMYY, NF_DATE_SYS_DDMMYYYY, NF_DATE_SYS_DMMMMYYYY, NF_DATE_SYS_DMMMYY, NF_DATE_SYS_DMMMYYYY, NF_DATE_SYS_MMYY, NF_DATE_SYSTEM_SHORT, NF_DATETIME_SYS_DDMMYYYY_HHMM, NF_DATETIME_SYS_DDMMYYYY_HHMMSS, NF_DATETIME_SYSTEM_SHORT_HHMM, NF_TIME_HHMM, NF_TIME_HHMMAMPM, NF_TIME_HHMMSS, NF_TIME_HHMMSSAMPM, NUMBER, PERCENT, and SCIENTIFIC.
CalendarWrapper * SvNumberFormatter::GetCalendar | ( | ) | const |
Definition at line 545 of file zforlist.cxx.
References OnDemandCalendarWrapper::get(), and xCalendar.
Referenced by ImpSvNumberformatScan::GetCal(), ImpSvNumberInputScan::GetDateRef(), ImpSvNumberInputScan::GetDayOfWeek(), ImpSvNumberInputScan::GetMonth(), ImpSvNumberInputScan::ImplGetMonth(), ImpSvNumberInputScan::InitText(), and ImpSvNumberInputScan::IsAcceptedDatePattern().
const CharClass * SvNumberFormatter::GetCharClass | ( | ) | const |
Definition at line 541 of file zforlist.cxx.
References OnDemandCharClass::get(), and xCharClass.
Referenced by ImpSvNumberformatScan::FinalScan(), ImpSvNumberformatScan::GetChrCls(), ImpSvNumberformatScan::GetColor(), ImpSvNumberInputScan::GetCurrency(), ImpSvNumberformatScan::GetKeyWord(), ImpSvNumberInputScan::GetTimeAmPm(), ImpSvNumberformatScan::InitCompatCur(), ImpSvNumberformatScan::InitSpecialKeyword(), ImpSvNumberInputScan::InitText(), ImpSvNumberInputScan::IsNumberFormat(), ImpSvNumberformatScan::Next_Symbol(), ImpSvNumberformatScan::SetDependentKeywords(), ImpSvNumberInputScan::StringContainsWord(), ImpSvNumberformatScan::Symbol_Division(), and TransformInput().
void SvNumberFormatter::GetCompatibilityCurrency | ( | OUString & | rSymbol, |
OUString & | rAbbrev | ||
) | const |
Get compatibility ("automatic" old style) currency from I18N locale data.
Definition at line 4075 of file zforlist.cxx.
References LocaleDataWrapper::areChecksEnabled(), LocaleDataWrapper::getAllCurrencies(), LocaleDataWrapper::getCurrBankSymbol(), LocaleDataWrapper::getCurrSymbol(), GetInstanceMutex(), LocaleDataWrapper::outputCheckMessage(), u, and xLocaleData.
Referenced by GenerateFormat(), and ImpSvNumberformatScan::InitCompatCur().
const css::uno::Reference< css::uno::XComponentContext > & SvNumberFormatter::GetComponentContext | ( | ) | const |
Definition at line 527 of file zforlist.cxx.
References m_xContext.
Referenced by ImpSvNumberformatScan::ImpSvNumberformatScan().
|
static |
Look up the corresponding NfCurrencyEntry matching rSymbol (may be CurrencySymbol or CurrencyAbbreviation) and possibly a rExtension (being yyy of [$xxx-yyy]) or a given language/country value.
Tries to match a rSymbol with rExtension first, then with eFormatLanguage, then rSymbol only. This is because a currency entry might have been constructed using I18N locale data where a used locale of a currency format code must not necessarily match the locale of the locale data itself, e.g. [$HK$-40C] (being "zh_HK" locale) in zh_CN locale data. Here the rExtension would have the value 0x40c but eFormatLanguage of the number format would have the value of zh_CN locale, the value with which the corresponding CurrencyEntry is constructed.
bFoundBank | Only used for output. If the return value is not <NULL> this value is set to <TRUE> if the matching entry was found by comparing rSymbol against the CurrencyAbbreviation (AKA BankSymbol). If the return value is <NULL> the value of bFoundBank is undefined. |
rSymbol | Currency symbol, preferably obtained of a format by a call to <method>SvNumberformat::GetNewCurrencySymbol()</method> |
rExtension | Currency extension, preferably obtained of a format by a call to <method>SvNumberformat::GetNewCurrencySymbol()</method> |
eFormatLanguage | The language/country value of the format of which rSymbol and rExtension are obtained (<method>SvNumberformat::GetLanguage()</method>). |
bOnlyStringLanguage | If <TRUE> only entries with language/country of rExtension are checked, no match on eFormatLanguage. If rExtension is empty all entries are checked. |
Definition at line 3983 of file zforlist.cxx.
References GetTheCurrencyTable(), ImpLookupCurrencyEntryLoopBody(), LANGUAGE_DONTKNOW, LANGUAGE_SYSTEM, nCount, SAL_WARN_IF, NfCurrencyTable::size(), and o3tl::toInt32().
|
static |
Return a NfCurrencyEntry matching a language/country.
If language/country is LANGUAGE_SYSTEM a <method>MatchSystemCurrency</method> call is tried to get an entry. If that fails or the corresponding language/country is not present the entry for LANGUAGE_SYSTEM is returned.
Definition at line 3678 of file zforlist.cxx.
References GetLanguage(), MsLangId::getRealLanguage(), GetTheCurrencyTable(), LANGUAGE_SYSTEM, MatchSystemCurrency(), nCount, and NfCurrencyTable::size().
Referenced by ImpSvNumberInputScan::GetCurrency(), GetNewCurrencySymbolString(), SvNumberFormatObj::getPropertyValue(), SvNumberFormatObj::getPropertyValues(), ImpGetDefaultCurrencyFormat(), and ImpGetDefaultSystemCurrencyFormat().
|
static |
Return a NfCurrencyEntry pointer matching a language/country and currency abbreviation (AKA banking symbol).
This method is meant for the configuration of the default currency.
Definition at line 3701 of file zforlist.cxx.
References GetLanguage(), MsLangId::getRealLanguage(), GetTheCurrencyTable(), nCount, and NfCurrencyTable::size().
sal_uInt16 SvNumberFormatter::GetCurrencyFormatStrings | ( | NfWSStringsDtor & | rStrArr, |
const NfCurrencyEntry & | rCurr, | ||
bool | bBank | ||
) | const |
Get all standard formats for a specific currency, formats are appended to the NfWSStringsDtor list.
bBank | <TRUE>: generate only format strings with currency abbreviation <FALSE>: mixed format strings |
Definition at line 4325 of file zforlist.cxx.
References addToCurrencyFormatsList(), GetInstanceMutex(), pFormatScanner, and xLocaleData.
Referenced by ImpGetDefaultCurrencyFormat(), and ImpGetDefaultSystemCurrencyFormat().
const OUString & SvNumberFormatter::GetDateSep | ( | ) | const |
Definition at line 555 of file zforlist.cxx.
References aDateSep.
Referenced by ImpSvNumberInputScan::ChangeIntl(), ImpSvNumberformatScan::FinalScan(), ImpSvNumberformatScan::Next_Symbol(), ImpSvNumberInputScan::ScanEndString(), ImpSvNumberInputScan::ScanMidString(), and ImpSvNumberformatScan::ScanType().
sal_uInt32 SvNumberFormatter::GetEditFormat | ( | double | fNumber, |
sal_uInt32 | nFIndex, | ||
SvNumFormatType | eType, | ||
SvNumberformat const * | pFormat, | ||
LanguageType | eForLocale = LANGUAGE_DONTKNOW |
||
) |
Return the corresponding edit format of a format.
nFIndex, eType and pFormat (if not nullptr) are assumed to match each other / be of one format. The locale to use is obtained from pFormat, if nullptr then LANGUAGE_SYSTEM is used. This can be overridden by specifying eForLocale other than LANGUAGE_DONTKNOW.
Definition at line 1593 of file zforlist.cxx.
References DATE, DATETIME, DURATION, eType, GetFormatIndex(), GetInstanceMutex(), SvNumberformat::GetLanguage(), GetStandardFormat(), GetTimeFormat(), SvNumberformat::IsIso8601(), LANGUAGE_DONTKNOW, LANGUAGE_SYSTEM, NF_DATE_DIN_MMDD, NF_DATE_DIN_YYMMDD, NF_DATE_DIN_YYYYMMDD, NF_DATE_ISO_YYYYMMDD, NF_DATE_SYS_DDMMYYYY, NF_DATETIME_ISO_YYYYMMDD_HHMMSS, NF_DATETIME_ISO_YYYYMMDD_HHMMSS000, NF_DATETIME_ISO_YYYYMMDDTHHMMSS, NF_DATETIME_ISO_YYYYMMDDTHHMMSS000, NF_DATETIME_SYS_DDMMYYYY_HHMMSS, NUMBER, and TIME.
Referenced by GetInputLineString().
const NfKeywordTable & SvNumberFormatter::GetEnglishKeywords | ( | ) | const |
Access for unit tests.
Definition at line 4964 of file zforlist.cxx.
References ImpSvNumberformatScan::GetEnglishKeywords().
const SvNumberformat * SvNumberFormatter::GetEntry | ( | sal_uInt32 | nKey | ) | const |
Return the format for a format index.
Definition at line 2531 of file zforlist.cxx.
References aFTable, and GetInstanceMutex().
Referenced by SvNumberformat::ConvertLanguage(), SvNumberFormatsObj::getByKey(), GetFormatEntry(), GetFormatStringForExcel(), GetIndexPuttingAndConverting(), SvNumberFormatObj::getPropertyValue(), and SvNumberFormatObj::getPropertyValues().
sal_uInt32 SvNumberFormatter::GetEntryKey | ( | std::u16string_view | sStr, |
LanguageType | eLnge = LANGUAGE_DONTKNOW |
||
) |
Return the format index of the format code string for language/country, or NUMBERFORMAT_ENTRY_NOT_FOUND.
Definition at line 3404 of file zforlist.cxx.
References GetInstanceMutex(), ImpGenerateCL(), ImpIsEntry(), IniLnge, and LANGUAGE_DONTKNOW.
Referenced by GetIndexPuttingAndConverting(), and SvNumberFormatsObj::queryKey().
SvNumberFormatTable & SvNumberFormatter::GetEntryTable | ( | SvNumFormatType | eType, |
sal_uInt32 & | FIndex, | ||
LanguageType | eLnge | ||
) |
Get table of formats of a specific type of a locale.
A format FIndex is tested whether it has the type and locale requested, if it doesn't match FIndex returns the default format for the type/locale. If no specific format is to be selected FIndex may be initialized to 0.
Definition at line 1143 of file zforlist.cxx.
References ActLnge, aFTable, ALL, ChangeIntl(), eType, GetFormatEntry(), GetInstanceMutex(), SvNumberformat::GetLanguage(), GetStandardFormat(), SvNumberformat::GetType(), ImpGetCLOffset(), and pFormatTable.
Referenced by ChangeCL(), GetFirstEntryTable(), and SvNumberFormatsObj::queryKeys().
NfEvalDateFormat SvNumberFormatter::GetEvalDateFormat | ( | ) | const |
Definition at line 3611 of file zforlist.cxx.
References eEvalDateFormat, and GetInstanceMutex().
Referenced by ImpSvNumberInputScan::GetDateRef(), ImpSvNumberInputScan::IsAcceptableIso8601(), and ImpSvNumberInputScan::IsAcceptedDatePattern().
SvNumberFormatTable & SvNumberFormatter::GetFirstEntryTable | ( | SvNumFormatType & | eType, |
sal_uInt32 & | FIndex, | ||
LanguageType & | rLnge | ||
) |
Get table of formats of the same type as FIndex; eType and rLnge are set accordingly.
An unknown format is set to Standard/General
Definition at line 1034 of file zforlist.cxx.
References ALL, ChangeIntl(), DATE, DATETIME, DEFINED, eType, GetEntryTable(), GetFormatEntry(), GetInstanceMutex(), SvNumberformat::GetLanguage(), SvNumberformat::GetMaskedType(), and IniLnge.
OUString SvNumberFormatter::GetFormatDecimalSep | ( | sal_uInt32 | nFormat | ) | const |
Return the decimal separator matching the locale of the given format.
Definition at line 2222 of file zforlist.cxx.
References GetFormatEntry(), GetInstanceMutex(), GetLangDecimalSep(), SvNumberformat::GetLanguage(), and GetNumDecimalSep().
|
private |
Definition at line 2518 of file zforlist.cxx.
References aFTable.
Referenced by GenerateFormat(), GetCalcCellReturn(), GetEntryTable(), GetFirstEntryTable(), GetFormatDecimalSep(), GetFormatIntegerDigits(), GetFormatPrecision(), GetFormatSpecialInfo(), GetInputLineString(), GetKeywords(), GetNewCurrencySymbolString(), GetOutputString(), GetSubstitutedEntry(), GetType(), GetUsedLanguages(), ImpGenerateAdditionalFormats(), ImpGetCLOffset(), ImpGetDefaultCurrencyFormat(), IsNatNum12(), IsNumberFormat(), IsTextFormat(), IsUserDefined(), MergeFormatter(), PutandConvertEntry(), PutEntry(), and ReplaceSystemCL().
|
private |
Definition at line 2526 of file zforlist.cxx.
References GetEntry().
sal_uInt32 SvNumberFormatter::GetFormatForLanguageIfBuiltIn | ( | sal_uInt32 | nFormat, |
LanguageType | eLnge = LANGUAGE_DONTKNOW |
||
) |
Return the format index of a builtin format for a specific language/country.
If nFormat is not a builtin format nFormat is returned.
Definition at line 3548 of file zforlist.cxx.
References GetInstanceMutex(), ImpGenerateCL(), IniLnge, LANGUAGE_DONTKNOW, SV_COUNTRY_LANGUAGE_OFFSET, and SV_MAX_COUNT_STANDARD_FORMATS.
Referenced by SvNumberFormatsObj::getFormatForLocale(), and GetIndexPuttingAndConverting().
sal_uInt32 SvNumberFormatter::GetFormatIndex | ( | NfIndexTableOffset | nTabOff, |
LanguageType | eLnge = LANGUAGE_DONTKNOW |
||
) |
Return the format index for a builtin format of a specific language.
Definition at line 3570 of file zforlist.cxx.
References GetInstanceMutex(), ImpGenerateCL(), indexTable, IniLnge, LANGUAGE_DONTKNOW, NF_INDEX_TABLE_ENTRIES, and NUMBERFORMAT_ENTRY_NOT_FOUND.
Referenced by GetEditFormat(), SvNumberFormatsObj::getFormatIndex(), GetStandardFormat(), GetTimeFormat(), GuessDateTimeFormat(), ImpSubstituteEntry(), IsNumberFormat(), and IsSpecialStandardFormat().
sal_uInt16 SvNumberFormatter::GetFormatIntegerDigits | ( | sal_uInt32 | nFormat | ) | const |
Count of integer digits.
Definition at line 2212 of file zforlist.cxx.
References GetFormatEntry(), SvNumberformat::GetFormatIntegerDigits(), and GetInstanceMutex().
sal_uInt16 SvNumberFormatter::GetFormatPrecision | ( | sal_uInt32 | nFormat | ) | const |
Count of decimals.
Definition at line 2202 of file zforlist.cxx.
References GetFormatEntry(), SvNumberformat::GetFormatPrecision(), GetInstanceMutex(), and pFormatScanner.
const ImpSvNumberformatScan * SvNumberFormatter::GetFormatScanner | ( | ) | const |
The following method is not to be used from outside but must be public for the InputScanner.
Definition at line 532 of file zforlist.cxx.
References pFormatScanner.
Referenced by ImpSvNumberInputScan::GetLogical().
sal_uInt32 SvNumberFormatter::GetFormatSpecialInfo | ( | const OUString & | rFormatString, |
bool & | bThousand, | ||
bool & | IsRed, | ||
sal_uInt16 & | nPrecision, | ||
sal_uInt16 & | nLeadingCnt, | ||
LanguageType | eLnge = LANGUAGE_DONTKNOW |
||
) |
Get additional info of a format code string, e.g.
for dialog box. Uses a temporary parse, if possible use only if format code is not present in container yet, otherwise ineffective.
Definition at line 2264 of file zforlist.cxx.
References ActLnge, ChangeIntl(), SvNumberformat::GetFormatSpecialInfo(), GetInstanceMutex(), IniLnge, LANGUAGE_DONTKNOW, pFormatScanner, and pStringScanner.
void SvNumberFormatter::GetFormatSpecialInfo | ( | sal_uInt32 | nFormat, |
bool & | bThousand, | ||
bool & | IsRed, | ||
sal_uInt16 & | nPrecision, | ||
sal_uInt16 & | nLeadingCnt | ||
) |
Get additional info of a format index, e.g. for dialog box.
Definition at line 2181 of file zforlist.cxx.
References GetFormatEntry(), SvNumberformat::GetFormatSpecialInfo(), GetInstanceMutex(), and pFormatScanner.
OUString SvNumberFormatter::GetFormatStringForExcel | ( | sal_uInt32 | nKey, |
const NfKeywordTable & | rKeywords, | ||
SvNumberFormatter & | rTempFormatter | ||
) | const |
Return a format code string suitable for Excel export.
rTempFormatter | SvNumberFormatter to use if a non-en-US format code needs to be converted and put, should not be the same formatter to not pollute the entries of this one here. |
Definition at line 899 of file zforlist.cxx.
References ChangeIntl(), DEFINED, GetEntry(), GetInstanceMutex(), SvtSysLocale::GetLanguageTag(), LanguageTag::getLanguageType(), GetLocaleData(), LANGUAGE_ENGLISH_US, LANGUAGE_SYSTEM, lcl_buildBooleanStringFormat(), LOGICAL, nType, NUMBERFORMAT_ENTRY_NOT_FOUND, PutandConvertEntry(), SAL_WARN, and SAL_WARN_IF.
|
staticprivate |
Definition at line 377 of file zforlist.cxx.
References GetGlobalMutex(), pFormatterRegistry, and SvNumberFormatterRegistry_Impl.
Referenced by ImpConstruct(), and resetTheCurrencyTable().
|
staticprivate |
Definition at line 365 of file zforlist.cxx.
Referenced by SvNumberFormatterRegistry_Impl::ConfigurationChanged(), GetFormatterRegistry(), ImpConstruct(), SetDefaultSystemCurrency(), and ~SvNumberFormatter().
sal_uInt32 SvNumberFormatter::GetIndexPuttingAndConverting | ( | OUString & | rString, |
LanguageType | eLnge, | ||
LanguageType | eSysLnge, | ||
SvNumFormatType & | rType, | ||
bool & | rNewInserted, | ||
sal_Int32 & | rCheckPos | ||
) |
Similar to <method>PutEntry</method> and <method>PutandConvertEntry</method> or <method>PutandConvertEntrySystem</method>, the format code string passed is considered to be of language/country eLnge.
If eLnge==LANGUAGE_SYSTEM the format code has to match eSysLnge, and if eSysLnge is not the current application locale the format code is converted to the current locale. Additionally, if the format code represents an old "automatic" currency format, it is converted to the new default currency format of the eLnge locale. The rString format code passed as an argument may get adapted in case eLnge was used (or is LANGUAGE_SYSTEM and eSysLnge is identical); in case it wasn't the method works on a copy instead, otherwise the resulting string would not match eSysLnge anymore.
This method was introduced to handle the legacy currency formats of the "autotbl.fmt" file used by Calc and Writer and convert them to fixed currency codes of the actual currency. Note that in the case of legacy currency formats no special attribution is converted, only the default currency format of the locale is chosen, and that new fixed currency codes are of course not converted to other currencies. The method may also be used as a general method taking, converting and inserting almost arbitrary format codes. To insert or use, for example, the default currency format code matching the current locale, the method could be called with
GetIndexPuttingAndConverting( "0 $", LANGUAGE_SYSTEM, LANGUAGE_ENGLISH_US, ...);
Definition at line 717 of file zforlist.cxx.
References CURRENCY, DeleteEntry(), GetEntry(), GetEntryKey(), GetFormatForLanguageIfBuiltIn(), GetInstanceMutex(), GetLanguageTag(), GetStandardFormat(), GetStandardIndex(), GetType(), SvNumberformat::HasNewCurrency(), LANGUAGE_SYSTEM, NUMBERFORMAT_ENTRY_NOT_FOUND, PutandConvertEntrySystem(), PutEntry(), and SAL_WARN.
NfIndexTableOffset SvNumberFormatter::GetIndexTableOffset | ( | sal_uInt32 | nFormat | ) | const |
Return enum index of a format index of a builtin format, NF_INDEX_TABLE_ENTRIES if it's not a builtin format.
Definition at line 3589 of file zforlist.cxx.
References indexTable, NF_INDEX_TABLE_ENTRIES, SV_COUNTRY_LANGUAGE_OFFSET, and SV_MAX_COUNT_STANDARD_FORMATS.
Referenced by GetCalcCellReturn().
void SvNumberFormatter::GetInputLineString | ( | const double & | fOutNumber, |
sal_uInt32 | nFIndex, | ||
OUString & | rOutString, | ||
bool | bFiltering = false , |
||
bool | bForceSystemLocale = false |
||
) |
Format a number according to the standard default format matching the given format index.
rOutString will be the real cell string (e.g. a number rounded by the cell format, which rounded value is used in the filtering condition now), instead of the EditFormat string (e.g a not rounded value, which is visible during editing).
Definition at line 1673 of file zforlist.cxx.
References ALL, ChangeIntl(), ChangeStandardPrec(), CURRENCY, eType, FRACTION, GetEditFormat(), GetFormatEntry(), SvNumberformat::GetFormatPrecision(), GetInstanceMutex(), SvNumberformat::GetLanguage(), SvNumberformat::GetMaskedType(), SvNumberformat::GetNumForInfoScannedType(), SvNumberformat::GetOutputString(), ImpSubstituteEntry(), INPUTSTRING_PRECISION, LANGUAGE_DONTKNOW, LANGUAGE_SYSTEM, NUMBER, PERCENT, pFormatScanner, SCIENTIFIC, ImpSvNumberformatScan::sErrStr, TIME, and ZF_STANDARD.
Referenced by SvNumberFormatterServiceObj::getInputString().
|
inlineprivate |
Definition at line 691 of file numformat.hxx.
References m_aMutex.
Referenced by ChangeCL(), ChangeIntl(), ChangeNullDate(), ChangeStandardPrec(), ClearMergeTable(), ConvertMergeTableToMap(), DeleteEntry(), FillKeywordTable(), FillKeywordTableForExcel(), GenerateFormat(), GetCalcCellReturn(), GetCompatibilityCurrency(), GetCurrencyFormatStrings(), GetEditFormat(), GetEntry(), GetEntryKey(), GetEntryTable(), GetEvalDateFormat(), GetFirstEntryTable(), GetFormatDecimalSep(), GetFormatForLanguageIfBuiltIn(), GetFormatIndex(), GetFormatIntegerDigits(), GetFormatPrecision(), GetFormatSpecialInfo(), GetFormatStringForExcel(), GetIndexPuttingAndConverting(), GetInputLineString(), GetKeyword(), GetKeywords(), GetLangDecimalSep(), GetLanguage(), GetMergeFormatIndex(), GetNewCurrencySymbolString(), GetNoZero(), GetNullDate(), GetOutputString(), GetPreviewString(), GetPreviewStringGuess(), GetStandardFormat(), GetStandardIndex(), GetStandardName(), GetStandardPrec(), GetSubstitutedEntry(), GetTimeFormat(), GetType(), GetUsedLanguages(), GetUserDefColor(), GetYear2000(), GuessDateTimeFormat(), HasMergeFormatTable(), IsNatNum12(), IsNumberFormat(), IsSpecialStandardFormat(), IsTextFormat(), IsUserDefined(), MergeFormatter(), PutandConvertEntry(), PutandConvertEntrySystem(), PutEntry(), SetColorLink(), SetEvalDateFormat(), SetNoZero(), SetYear2000(), and TestNewString().
OUString SvNumberFormatter::GetKeyword | ( | LanguageType | eLnge, |
sal_uInt16 | nIndex | ||
) |
Return a keyword for a language/country and NfKeywordIndex for XML import, to generate number format strings.
Definition at line 975 of file zforlist.cxx.
References ChangeIntl(), GetInstanceMutex(), NF_KEYWORD_ENTRIES_COUNT, nIndex, pFormatScanner, and SAL_WARN.
const NfKeywordTable & SvNumberFormatter::GetKeywords | ( | sal_uInt32 | nKey | ) |
Obtain NfKeywordTable used with a format, possibly localized.
XXX NOTE: the content (actual keywords) is only valid as long as the locale context of the associated ImpSvNumberformatScan instance does not change to a locale with different keywords, which may happen anytime with a call (implicit or explicit) to SvNumberFormatter::ChangeIntl(). If needed longer, copy-create another NfKeywordTable instance or copy individual elements.
If the format specified with nKey does not exist, the content of the NfKeywordTable matches the locale with which the SvNumberFormatter instance was created and initialized.
This function preliminary exists for unit tests and otherwise is pretty much useless.
Definition at line 4953 of file zforlist.cxx.
References ChangeIntl(), GetFormatEntry(), GetInstanceMutex(), SvNumberformat::GetLanguage(), IniLnge, and pFormatScanner.
OUString SvNumberFormatter::GetLangDecimalSep | ( | LanguageType | nLang | ) | const |
Return the decimal separator matching the given locale / LanguageType.
Definition at line 2233 of file zforlist.cxx.
References ActLnge, OnDemandLocaleDataWrapper::changeLocale(), OnDemandLocaleDataWrapper::getCurrentLanguage(), GetInstanceMutex(), LocaleDataWrapper::getLanguageTag(), LocaleDataWrapper::getNumDecimalSep(), GetNumDecimalSep(), and xLocaleData.
Referenced by GetFormatDecimalSep(), and SvNumberformat::SvNumberformat().
LanguageType SvNumberFormatter::GetLanguage | ( | ) | const |
The language with which the formatter was initialized (system setting), NOT the current language after a ChangeIntl()
Definition at line 1303 of file zforlist.cxx.
References GetInstanceMutex(), and IniLnge.
Referenced by GetCurrencyEntry(), ImpSvNumberInputScan::IsAcceptedDatePattern(), and SetDefaultSystemCurrency().
const LanguageTag & SvNumberFormatter::GetLanguageTag | ( | ) | const |
The following methods are not to be used from outside but must be public for the InputScanner and FormatScanner.
Definition at line 534 of file zforlist.cxx.
References maLanguageTag.
Referenced by GetIndexPuttingAndConverting(), ImpSvNumberInputScan::GetMonth(), ImpGenerateAdditionalFormats(), ImpGenerateFormats(), ImpInitCurrencyTable(), and TransformInput().
|
static |
Return a NfCurrencyEntry pointer matching the symbol combination of a LegacyOnly currency.
Note that this means only that the currency matching both symbols was once used in the Office, but is not offered in dialogs anymore. It doesn't even mean that the currency symbol combination is valid, since the reason for removing it may have been just that. #i61657#
Definition at line 3719 of file zforlist.cxx.
References GetTheCurrencyTable(), nCount, and NfCurrencyTable::size().
const LocaleDataWrapper * SvNumberFormatter::GetLocaleData | ( | ) | const |
Definition at line 543 of file zforlist.cxx.
References OnDemandLocaleDataWrapper::get(), and xLocaleData.
Referenced by ChangeIntl(), ImpSvNumberformatScan::FinalScan(), ImpSvNumberformatScan::GetColor(), ImpSvNumberInputScan::GetCurrency(), ImpSvNumberInputScan::GetDateOrder(), ImpSvNumberInputScan::GetDateRef(), GetFormatStringForExcel(), ImpSvNumberformatScan::GetLoc(), ImpSvNumberInputScan::GetThousandSep(), ImpSvNumberInputScan::GetTime100SecSep(), ImpSvNumberInputScan::GetTimeAmPm(), ImpConstruct(), ImpGenerateFormats(), ImpSvNumberformatScan::InitSpecialKeyword(), ImpSvNumberInputScan::IsAcceptedDatePattern(), ImpSvNumberformatScan::Next_Symbol(), ImpSvNumberInputScan::ScanEndString(), ImpSvNumberInputScan::ScanMidString(), ImpSvNumberInputScan::ScanStartString(), ImpSvNumberformatScan::ScanType(), and ImpSvNumberformatScan::SetDependentKeywords().
size_t SvNumberFormatter::GetMaxDefaultColors | ( | ) | const |
Access for unit tests.
Definition at line 4974 of file zforlist.cxx.
References ImpSvNumberformatScan::GetMaxDefaultColors().
sal_uInt32 SvNumberFormatter::GetMergeFormatIndex | ( | sal_uInt32 | nOldFmt | ) | const |
Return the new format index for an old format index, if a merge table exists.
Definition at line 4412 of file zforlist.cxx.
References GetInstanceMutex(), and pMergeTable.
const NativeNumberWrapper * SvNumberFormatter::GetNatNum | ( | ) | const |
Definition at line 547 of file zforlist.cxx.
References OnDemandNativeNumberWrapper::get(), and xNatNum.
Referenced by SvNumberformat::impTransliterateImpl(), and TransformInput().
bool SvNumberFormatter::GetNewCurrencySymbolString | ( | sal_uInt32 | nFormat, |
OUString & | rSymbol, | ||
const NfCurrencyEntry ** | ppEntry, | ||
bool * | pBank = nullptr |
||
) | const |
Whether nFormat is of type css::util::NumberFormat::CURRENCY and the format code contains a new SYMBOLTYPE_CURRENCY and if so which one [$xxx-nnn].
If ppEntry is not NULL and exactly one entry is found, a [$xxx-nnn] is returned, even if the format code only contains [$xxx] !
Definition at line 3923 of file zforlist.cxx.
References GetCurrencyEntry(), GetFormatEntry(), GetInstanceMutex(), SvNumberformat::GetLanguage(), and SvNumberformat::GetNewCurrencySymbol().
Referenced by GenerateFormat().
bool SvNumberFormatter::GetNoZero | ( | ) | const |
Return whether zero suppression is switched on.
Definition at line 439 of file zforlist.cxx.
References bNoZero, and GetInstanceMutex().
Referenced by SvNumberFormatSettingsObj::getPropertyValue().
const Date & SvNumberFormatter::GetNullDate | ( | ) | const |
Return the reference date.
Definition at line 415 of file zforlist.cxx.
References GetInstanceMutex(), and pFormatScanner.
Referenced by SvNumberFormatSettingsObj::getPropertyValue().
const OUString & SvNumberFormatter::GetNumDecimalSep | ( | ) | const |
Definition at line 549 of file zforlist.cxx.
References aDecimalSep.
Referenced by ImpSvNumberInputScan::ChangeIntl(), ImpSvNumberformatScan::FinalScan(), GenerateFormat(), ImpSvNumberInputScan::GetDecSep(), GetFormatDecimalSep(), GetLangDecimalSep(), ImpGetFormatCodeIndex(), IsDecimalSep(), ImpSvNumberformatScan::Next_Symbol(), and SvNumberformat::SvNumberformat().
const OUString & SvNumberFormatter::GetNumDecimalSepAlt | ( | ) | const |
Definition at line 551 of file zforlist.cxx.
References aDecimalSepAlt.
Referenced by ImpSvNumberInputScan::ChangeIntl(), ImpSvNumberInputScan::GetDecSep(), and IsDecimalSep().
const OUString & SvNumberFormatter::GetNumThousandSep | ( | ) | const |
Definition at line 553 of file zforlist.cxx.
References aThousandSep.
Referenced by ImpSvNumberformatScan::FinalScan(), GenerateFormat(), ImpSvNumberInputScan::GetThousandSep(), SvNumberformat::ImpDigitFill(), ImpSvNumberformatScan::Next_Symbol(), ImpSvNumberInputScan::SkipThousands(), and SvNumberformat::SvNumberformat().
|
inline |
Access for input scanner to temporarily (!) switch locales.
Definition at line 568 of file numformat.hxx.
Referenced by ImpSvNumberInputScan::IsAcceptedDatePattern().
void SvNumberFormatter::GetOutputString | ( | const double & | fOutNumber, |
sal_uInt32 | nFIndex, | ||
OUString & | sOutString, | ||
const Color ** | ppColor, | ||
bool | bUseStarFormat = false |
||
) |
Format a number according to a format index, return string and color.
Definition at line 1794 of file zforlist.cxx.
References bNoZero, ChangeIntl(), GetFormatEntry(), GetInstanceMutex(), SvNumberformat::GetLanguage(), SvNumberformat::GetOutputString(), ImpSubstituteEntry(), SvNumberformat::SetStarFormatSupport(), and ZF_STANDARD.
Referenced by SvNumberFormatterServiceObj::convertNumberToString(), SvNumberFormatterServiceObj::formatString(), GetPreviewString(), GetPreviewStringGuess(), SvNumberFormatterServiceObj::queryColorForNumber(), and SvNumberFormatterServiceObj::queryColorForString().
void SvNumberFormatter::GetOutputString | ( | const OUString & | sString, |
sal_uInt32 | nFIndex, | ||
OUString & | sOutString, | ||
const Color ** | ppColor, | ||
bool | bUseStarFormat = false |
||
) |
Format a string according to a format index, return string and color.
Formats only if the format code is of type text or the 4th subcode of a format code is specified, otherwise sOutString will be == ""
Definition at line 1760 of file zforlist.cxx.
References ChangeIntl(), GetFormatEntry(), GetInstanceMutex(), SvNumberformat::GetLanguage(), SvNumberformat::GetOutputString(), SvNumberformat::HasTextFormat(), SvNumberformat::IsTextFormat(), SvNumberformat::SetStarFormatSupport(), and ZF_STANDARD_TEXT.
bool SvNumberFormatter::GetPreviewString | ( | const OUString & | sFormatString, |
const OUString & | sPreviewString, | ||
OUString & | sOutString, | ||
const Color ** | ppColor, | ||
LanguageType | eLnge = LANGUAGE_DONTKNOW |
||
) |
Format a string according to a format code string to be scanned.
Definition at line 1971 of file zforlist.cxx.
References ActLnge, ChangeIntl(), SvNumberformat::GetFormatstring(), GetInstanceMutex(), GetOutputString(), SvNumberformat::GetOutputString(), SvNumberformat::HasTextFormat(), ImpGenerateCL(), ImpIsEntry(), IniLnge, SvNumberformat::IsTextFormat(), LANGUAGE_DONTKNOW, NUMBERFORMAT_ENTRY_NOT_FOUND, pFormatScanner, and pStringScanner.
bool SvNumberFormatter::GetPreviewString | ( | const OUString & | sFormatString, |
double | fPreviewNumber, | ||
OUString & | sOutString, | ||
const Color ** | ppColor, | ||
LanguageType | eLnge, | ||
bool | bUseStarFormat = false |
||
) |
Format a number according to a format code string to be scanned.
Definition at line 1817 of file zforlist.cxx.
References ActLnge, ChangeIntl(), SvNumberformat::GetFormatstring(), GetInstanceMutex(), GetOutputString(), SvNumberformat::GetOutputString(), ImpGenerateCL(), ImpIsEntry(), IniLnge, LANGUAGE_DONTKNOW, NUMBERFORMAT_ENTRY_NOT_FOUND, pFormatScanner, pStringScanner, and SvNumberformat::SetStarFormatSupport().
Referenced by SvNumberFormatterServiceObj::convertNumberToPreviewString(), and SvNumberFormatterServiceObj::queryPreviewColorForNumber().
bool SvNumberFormatter::GetPreviewStringGuess | ( | const OUString & | sFormatString, |
double | fPreviewNumber, | ||
OUString & | sOutString, | ||
const Color ** | ppColor, | ||
LanguageType | eLnge = LANGUAGE_DONTKNOW |
||
) |
Same as <method>GetPreviewString</method> but the format code string may be either language/country eLnge or en_US english US.
Definition at line 1870 of file zforlist.cxx.
References ActLnge, ChangeIntl(), SvNumberformat::GetFormatstring(), GetInstanceMutex(), GetOutputString(), ImpGenerateCL(), ImpIsEntry(), IniLnge, utl::TransliterationWrapper::isEqual(), LANGUAGE_DONTKNOW, LANGUAGE_ENGLISH_US, ImpSvNumberformatScan::LocaleLegacy, NUMBERFORMAT_ENTRY_NOT_FOUND, pFormatScanner, pStringScanner, CharClass::uppercase(), xCharClass, and xTransliteration.
Referenced by SvNumberFormatterServiceObj::convertNumberToPreviewString(), and SvNumberFormatterServiceObj::queryPreviewColorForNumber().
const std::vector< Color > & SvNumberFormatter::GetStandardColors | ( | ) | const |
Access for unit tests.
Definition at line 4969 of file zforlist.cxx.
References ImpSvNumberformatScan::GetStandardColors().
sal_uInt32 SvNumberFormatter::GetStandardFormat | ( | double | fNumber, |
sal_uInt32 | nFIndex, | ||
SvNumFormatType | eType, | ||
LanguageType | eLnge | ||
) |
Return the format index of the default format of a type for language/country.
Maybe not the default format but a special builtin format, e.g. for NF_TIME_HH_MMSS00, or NF_TIME_HH_MMSS if fNumber >= 1.0
Definition at line 1539 of file zforlist.cxx.
References DURATION, eType, GetInstanceMutex(), GetStandardFormat(), GetTimeFormat(), IsSpecialStandardFormat(), and TIME.
sal_uInt32 SvNumberFormatter::GetStandardFormat | ( | sal_uInt32 | nFIndex, |
SvNumFormatType | eType, | ||
LanguageType | eLnge | ||
) |
Return the format index of the default format of a type for language/country.
Maybe not the default format but a special builtin format, e.g. for NF_TIME_HH_MMSS00, if that format is passed in nFIndex.
Definition at line 1501 of file zforlist.cxx.
References eType, GetInstanceMutex(), GetStandardFormat(), and IsSpecialStandardFormat().
sal_uInt32 SvNumberFormatter::GetStandardFormat | ( | SvNumFormatType | eType, |
LanguageType | eLnge = LANGUAGE_DONTKNOW |
||
) |
Return the format index of the default format of a type for language/country.
Definition at line 1455 of file zforlist.cxx.
References ALL, CURRENCY, DATE, DATETIME, DEFINED, DURATION, eType, FRACTION, GetFormatIndex(), GetInstanceMutex(), ImpGenerateCL(), ImpGetDefaultCurrencyFormat(), ImpGetDefaultFormat(), ImpGetDefaultSystemCurrencyFormat(), IniLnge, LANGUAGE_DONTKNOW, LANGUAGE_SYSTEM, LOGICAL, NF_TIME_HH_MMSS, NUMBER, PERCENT, SCIENTIFIC, TEXT, TIME, UNDEFINED, ZF_STANDARD, ZF_STANDARD_FRACTION, ZF_STANDARD_LOGICAL, and ZF_STANDARD_TEXT.
Referenced by GetEditFormat(), GetEntryTable(), GetIndexPuttingAndConverting(), SvNumberFormatsObj::getStandardFormat(), GetStandardFormat(), GetStandardIndex(), GetTimeFormat(), ImpSubstituteEntry(), and IsNumberFormat().
sal_uInt32 SvNumberFormatter::GetStandardIndex | ( | LanguageType | eLnge = LANGUAGE_DONTKNOW | ) |
Return the format index of the standard default number format for language/country.
Definition at line 3416 of file zforlist.cxx.
References GetInstanceMutex(), GetStandardFormat(), IniLnge, LANGUAGE_DONTKNOW, and NUMBER.
Referenced by GetIndexPuttingAndConverting(), and SvNumberFormatsObj::getStandardIndex().
OUString SvNumberFormatter::GetStandardName | ( | LanguageType | eLnge | ) |
Return the GENERAL keyword in proper case ("General") for a language/country, used in XML import.
Definition at line 989 of file zforlist.cxx.
References ChangeIntl(), GetInstanceMutex(), and pFormatScanner.
Referenced by FillKeywordTableForExcel().
sal_uInt16 SvNumberFormatter::GetStandardPrec | ( | ) | const |
Return the standard decimal precision.
Definition at line 433 of file zforlist.cxx.
References GetInstanceMutex(), and pFormatScanner.
Referenced by SvNumberFormatSettingsObj::getPropertyValue().
const SvNumberformat * SvNumberFormatter::GetSubstitutedEntry | ( | sal_uInt32 | nKey, |
sal_uInt32 & | o_rNewKey | ||
) | const |
Obtain substituted GetFormatEntry(), i.e. system formats.
Definition at line 2540 of file zforlist.cxx.
References GetFormatEntry(), GetInstanceMutex(), and ImpSubstituteEntry().
|
static |
Return a NfCurrencyTable with pointers to <type>NfCurrencyEntry</type> entries.
Definition at line 3660 of file zforlist.cxx.
References bCurrencyTableInitialized, and ImpInitCurrencyTable().
Referenced by GetCurrencyEntry(), GetLegacyOnlyCurrencyEntry(), IsLocaleInstalled(), MatchSystemCurrency(), and SetDefaultSystemCurrency().
sal_uInt32 SvNumberFormatter::GetTimeFormat | ( | double | fNumber, |
LanguageType | eLnge, | ||
bool | bForceDuration | ||
) |
Return a time format that best matches fNumber.
Definition at line 1511 of file zforlist.cxx.
References GetFormatIndex(), GetInstanceMutex(), GetStandardFormat(), NF_TIME_HH_MMSS, NF_TIME_HH_MMSS00, NF_TIME_MMSS00, and TIME.
Referenced by GetEditFormat(), GetStandardFormat(), and GuessDateTimeFormat().
const ::utl::TransliterationWrapper * SvNumberFormatter::GetTransliteration | ( | ) | const |
Definition at line 536 of file zforlist.cxx.
References OnDemandTransliterationWrapper::get(), and xTransliteration.
Referenced by ImpSvNumberInputScan::ScanStringNumFor().
SvNumFormatType SvNumberFormatter::GetType | ( | sal_uInt32 | nFIndex | ) | const |
Get the type of a format (or css::util::NumberFormat::UNDEFINED if no entry), but with css::util::NumberFormat::DEFINED masked out.
Definition at line 3426 of file zforlist.cxx.
References ALL, DEFINED, eType, GetFormatEntry(), GetInstanceMutex(), SvNumberformat::GetMaskedType(), and UNDEFINED.
Referenced by GetIndexPuttingAndConverting().
void SvNumberFormatter::GetUsedLanguages | ( | std::vector< LanguageType > & | rList | ) |
Fill rList with the language/country codes that have been allocated.
Definition at line 799 of file zforlist.cxx.
References GetFormatEntry(), GetInstanceMutex(), SvNumberformat::GetLanguage(), MaxCLOffset, and SV_COUNTRY_LANGUAGE_OFFSET.
Color * SvNumberFormatter::GetUserDefColor | ( | sal_uInt16 | nIndex | ) |
Do the CallBack to ColorTable.
Definition at line 393 of file zforlist.cxx.
References aColorLink, Link< typename Arg, typename Ret >::Call(), GetInstanceMutex(), Link< typename Arg, typename Ret >::IsSet(), and nIndex.
Referenced by ImpSvNumberformatScan::GetColor().
sal_uInt16 SvNumberFormatter::GetYear2000 | ( | ) | const |
Definition at line 3624 of file zforlist.cxx.
References GetInstanceMutex(), and pStringScanner.
Referenced by SvNumberFormatSettingsObj::getPropertyValue().
|
static |
Definition at line 3641 of file zforlist.cxx.
References utl::ConfigManager::IsFuzzing().
Referenced by ImpSvNumberInputScan::ImpSvNumberInputScan().
sal_uInt32 SvNumberFormatter::GuessDateTimeFormat | ( | SvNumFormatType & | rType, |
double | fNumber, | ||
LanguageType | eLnge | ||
) |
Return a format and type that best matches the value of fNumber if fNumber is assumed to be a date, time or datetime value, but unknown which.
Originally introduced for Chart databrowser editor, probably should not be used otherwise.
Definition at line 1557 of file zforlist.cxx.
References DATE, DATETIME, GetFormatIndex(), GetInstanceMutex(), GetTimeFormat(), NF_DATE_SYS_DDMMYYYY, NF_DATETIME_SYS_DDMMYYYY_HHMMSS, and TIME.
bool SvNumberFormatter::HasMergeFormatTable | ( | ) | const |
Whether a merge table is present or not.
Definition at line 4426 of file zforlist.cxx.
References GetInstanceMutex(), and pMergeTable.
Referenced by ConvertMergeTableToMap().
|
private |
Definition at line 2417 of file zforlist.cxx.
References LocaleDataWrapper::appendLocaleInfo(), LocaleDataWrapper::areChecksEnabled(), Default, LocaleDataWrapper::outputCheckMessage(), and xLocaleData.
Referenced by ImpGenerateAdditionalFormats(), and ImpGenerateFormats().
|
private |
Definition at line 300 of file zforlist.cxx.
References ActLnge, aDateSep, aDecimalSep, aDecimalSepAlt, aThousandSep, bNoZero, OnDemandCharClass::changeLocale(), eEvalDateFormat, LocaleDataWrapper::getDateSep(), GetFormatterRegistry(), GetGlobalMutex(), LanguageTag::getLocale(), GetLocaleData(), LocaleDataWrapper::getNumDecimalSep(), LocaleDataWrapper::getNumDecimalSepAlt(), LocaleDataWrapper::getNumThousandSep(), ImpGenerateFormats(), IniLnge, OnDemandNativeNumberWrapper::init(), OnDemandCalendarWrapper::init(), OnDemandLocaleDataWrapper::init(), OnDemandTransliterationWrapper::init(), SvNumberFormatterRegistry_Impl::Insert(), LANGUAGE_DONTKNOW, m_xContext, maLanguageTag, MaxCLOffset, nDefaultSystemCurrencyFormat, NF_EVALDATEFORMAT_INTL, NUMBERFORMAT_ENTRY_NOT_FOUND, pFormatScanner, pFormatTable, pMergeTable, pStringScanner, LanguageTag::reset(), UNKNOWN_SUBSTITUTE, xCalendar, xCharClass, xLocaleData, xNatNum, and xTransliteration.
Referenced by SvNumberFormatter().
|
private |
no default on currency
Definition at line 3049 of file zforlist.cxx.
References GetFormatEntry(), GetLanguageTag(), SvNumberformat::GetLastInsertKey(), LanguageTag::getLocale(), ImpAdjustFormatCodeDefault(), ImpInsertFormat(), NF_CURRENCY_1000DEC2_CCC, NF_INDEX_TABLE_ENTRIES, NF_INDEX_TABLE_RESERVED_START, nPos, SAL_WARN, SvNumberformat::SetLastInsertKey(), SV_COUNTRY_LANGUAGE_OFFSET, and ZF_STANDARD.
Referenced by ImpGenerateFormats(), and ReplaceSystemCL().
|
private |
Definition at line 1078 of file zforlist.cxx.
References ActLnge, LocaleDataWrapper::appendLocaleInfo(), LocaleDataWrapper::areChecksEnabled(), ChangeIntl(), LanguageTag::equals(), LocaleDataWrapper::getAllFormats(), LocaleDataWrapper::getLoadedLanguageTag(), i, ImpGenerateFormats(), ImpGetCLOffset(), maLanguageTag, MaxCLOffset, LocaleDataWrapper::outputCheckMessage(), SV_COUNTRY_LANGUAGE_OFFSET, u, and xLocaleData.
Referenced by ChangeCL(), GenerateFormat(), GetEntryKey(), GetFormatForLanguageIfBuiltIn(), GetFormatIndex(), GetPreviewString(), GetPreviewStringGuess(), GetStandardFormat(), IsUserDefined(), MergeFormatter(), PutEntry(), and TestNewString().
|
private |
"??/" would be interpreted by the compiler as a trigraph for '\'
"??/" would be interpreted by the compiler as a trigraph for '\'
Definition at line 2575 of file zforlist.cxx.
References ActLnge, aFTable, LocaleDataWrapper::areChecksEnabled(), GetLanguageTag(), LanguageTag::getLocale(), GetLocaleData(), LocaleDataWrapper::getTime100SecSep(), SvNumberformat::GetType(), ImpAdjustFormatCodeDefault(), ImpGenerateAdditionalFormats(), ImpGetFormatCodeIndex(), ImpInsertFormat(), LOGICAL, m_xContext, NF_CURRENCY_1000DEC2, NF_CURRENCY_1000DEC2_CCC, NF_CURRENCY_1000DEC2_DASHED, NF_CURRENCY_1000DEC2_RED, NF_CURRENCY_1000INT, NF_CURRENCY_1000INT_RED, NF_DATE_DEF_NNDDMMMYY, NF_DATE_DIN_DMMMMYYYY, NF_DATE_DIN_DMMMYYYY, NF_DATE_DIN_MMDD, NF_DATE_DIN_YYMMDD, NF_DATE_DIN_YYYYMMDD, NF_DATE_MMMM, NF_DATE_QQJJ, NF_DATE_SYS_DDMMM, NF_DATE_SYS_DDMMYY, NF_DATE_SYS_DDMMYYYY, NF_DATE_SYS_DMMMMYYYY, NF_DATE_SYS_DMMMYY, NF_DATE_SYS_DMMMYYYY, NF_DATE_SYS_MMYY, NF_DATE_SYS_NNDMMMMYYYY, NF_DATE_SYS_NNDMMMYY, NF_DATE_SYS_NNNNDMMMMYYYY, NF_DATE_SYSTEM_LONG, NF_DATE_SYSTEM_SHORT, NF_DATETIME_SYS_DDMMYYYY_HHMM, NF_DATETIME_SYS_DDMMYYYY_HHMMSS, NF_DATETIME_SYSTEM_SHORT_HHMM, NF_KEY_DD, NF_KEY_HH, NF_KEY_MM, NF_KEY_MMI, NF_KEY_SS, NF_KEY_WW, NF_KEY_YYYY, NF_NUMBER_1000DEC2, NF_NUMBER_1000INT, NF_NUMBER_DEC2, NF_NUMBER_INT, NF_NUMBER_STANDARD, NF_NUMBER_SYSTEM, NF_PERCENT_DEC2, NF_PERCENT_INT, NF_SCIENTIFIC_000E00, NF_SCIENTIFIC_000E000, NF_TIME_HH_MMSS, NF_TIME_HH_MMSS00, NF_TIME_HHMM, NF_TIME_HHMMAMPM, NF_TIME_HHMMSS, NF_TIME_HHMMSSAMPM, NF_TIME_MMSS00, NUMBER, LocaleDataWrapper::outputCheckMessage(), pFormatScanner, pStringScanner, SAL_WARN, SvNumberformat::SetComment(), SvNumberformat::SetLastInsertKey(), SvNumberformat::SetStandard(), SvNumberformat::SetType(), SV_MAX_COUNT_STANDARD_FORMATS, TEXT, u, xLocaleData, ZF_STANDARD, ZF_STANDARD_CURRENCY, ZF_STANDARD_DATE, ZF_STANDARD_DATE_DIN_DMMMMYYYY, ZF_STANDARD_DATE_DIN_DMMMYYYY, ZF_STANDARD_DATE_DIN_MMDD, ZF_STANDARD_DATE_DIN_YYMMDD, ZF_STANDARD_DATE_DIN_YYYYMMDD, ZF_STANDARD_DATE_SYS_DMMMMYYYY, ZF_STANDARD_DATE_SYS_DMMMYYYY, ZF_STANDARD_DATE_SYS_NNDMMMMYYYY, ZF_STANDARD_DATE_SYS_NNDMMMYY, ZF_STANDARD_DATE_SYS_NNNNDMMMMYYYY, ZF_STANDARD_DATE_WW, ZF_STANDARD_DATETIME, ZF_STANDARD_FRACTION, ZF_STANDARD_LOGICAL, ZF_STANDARD_PERCENT, ZF_STANDARD_SCIENTIFIC, ZF_STANDARD_TEXT, and ZF_STANDARD_TIME.
Referenced by ImpConstruct(), ImpGenerateCL(), and ReplaceSystemCL().
|
private |
Definition at line 997 of file zforlist.cxx.
References GetFormatEntry(), SvNumberformat::GetLanguage(), MaxCLOffset, and SV_COUNTRY_LANGUAGE_OFFSET.
Referenced by GetEntryTable(), ImpGenerateCL(), ImpGetDefaultCurrencyFormat(), ImpGetDefaultFormat(), and ReplaceSystemCL().
|
private |
Definition at line 3817 of file zforlist.cxx.
References ActLnge, aDefaultFormatKeys, aFTable, CURRENCY, DBG_ASSERT, GetCurrencyEntry(), GetCurrencyFormatStrings(), GetFormatEntry(), SvNumberformat::GetType(), ImpGetCLOffset(), SvNumberformat::IsStandard(), nType, NUMBERFORMAT_ENTRY_NOT_FOUND, PutEntry(), SvNumberformat::SetStandard(), SV_COUNTRY_LANGUAGE_OFFSET, and ZF_STANDARD_CURRENCY.
Referenced by GetStandardFormat().
|
private |
Definition at line 1375 of file zforlist.cxx.
References ActLnge, aDefaultFormatKeys, aFTable, DATE, DATETIME, DURATION, SvNumberformat::GetMaskedType(), ImpGetCLOffset(), SvNumberformat::IsStandard(), nType, NUMBERFORMAT_ENTRY_NOT_FOUND, PERCENT, SCIENTIFIC, SV_COUNTRY_LANGUAGE_OFFSET, TIME, ZF_STANDARD, ZF_STANDARD_DATE, ZF_STANDARD_DATETIME, ZF_STANDARD_DURATION, ZF_STANDARD_PERCENT, ZF_STANDARD_SCIENTIFIC, and ZF_STANDARD_TIME.
Referenced by GetStandardFormat().
|
private |
Definition at line 3795 of file zforlist.cxx.
References DBG_ASSERT, GetCurrencyEntry(), GetCurrencyFormatStrings(), LANGUAGE_SYSTEM, nDefaultSystemCurrencyFormat, nType, NUMBERFORMAT_ENTRY_NOT_FOUND, and PutEntry().
Referenced by GetStandardFormat().
|
private |
Definition at line 2368 of file zforlist.cxx.
References LocaleDataWrapper::appendLocaleInfo(), LocaleDataWrapper::areChecksEnabled(), GetNumDecimalSep(), NF_CURRENCY_1000DEC2, NF_CURRENCY_1000DEC2_CCC, NF_CURRENCY_1000INT, NF_CURRENCY_1000INT_RED, NF_CURRENCY_END, NF_CURRENCY_START, LocaleDataWrapper::outputCheckMessage(), and xLocaleData.
Referenced by ImpGenerateFormats().
|
staticprivate |
Definition at line 4150 of file zforlist.cxx.
References LocaleDataWrapper::areChecksEnabled(), bCurrencyTableInitialized, NfCurrencyTable::begin(), LanguageTag::convertToLanguageType(), Default, SvtSysLocaleOptions::GetCurrencyAbbrevAndLanguage(), LocaleDataWrapper::getInstalledLocaleNames(), SvtSysLocale::GetLanguageTag(), GetLanguageTag(), LanguageTag::getLanguageType(), NfCurrencyTable::insert(), LANGUAGE_SYSTEM, lcl_CheckCurrencySymbolPosition(), LINK, n, nSystemCurrencyPosition, LocaleDataWrapper::outputCheckMessage(), SAL_INFO, and SvtSysLocaleOptions::SetCurrencyChangeLink().
Referenced by GetTheCurrencyTable().
|
private |
Definition at line 2062 of file zforlist.cxx.
References ActLnge, aFTable, LocaleDataWrapper::appendLocaleInfo(), LocaleDataWrapper::areChecksEnabled(), LanguageTag::getBcp47(), ImpIsEntry(), maLanguageTag, NF_CURRENCY_1000DEC2, NF_CURRENCY_1000DEC2_CCC, NF_CURRENCY_1000DEC2_DASHED, NF_CURRENCY_1000DEC2_RED, NF_INDEX_TABLE_ENTRIES, NF_INDEX_TABLE_RESERVED_START, nPos, NUMBERFORMAT_ENTRY_NOT_FOUND, LocaleDataWrapper::outputCheckMessage(), pFormatScanner, pStringScanner, SAL_WARN, SAL_WARN_IF, SvNumberformat::StripNewCurrencyDelimiters(), SV_COUNTRY_LANGUAGE_OFFSET, and xLocaleData.
Referenced by ImpGenerateAdditionalFormats(), and ImpGenerateFormats().
|
private |
Definition at line 1012 of file zforlist.cxx.
References aFTable, and NUMBERFORMAT_ENTRY_NOT_FOUND.
Referenced by GetEntryKey(), GetPreviewString(), GetPreviewStringGuess(), ImpInsertFormat(), IsUserDefined(), MergeFormatter(), PutEntry(), and TestNewString().
|
staticprivate |
Definition at line 3876 of file zforlist.cxx.
References MatchSystemCurrency(), nPos, and pData.
Referenced by GetCurrencyEntry().
|
private |
Definition at line 3125 of file zforlist.cxx.
Referenced by GenerateFormat().
|
private |
Definition at line 2550 of file zforlist.cxx.
References aFTable, GetFormatIndex(), GetStandardFormat(), SvNumberformat::IsSubstituted(), SvNumberformat::IsSystemLongDateFormat(), SvNumberformat::IsSystemTimeFormat(), LANGUAGE_SYSTEM, NF_DATE_SYSTEM_LONG, and TIME.
Referenced by GetInputLineString(), GetOutputString(), GetSubstitutedEntry(), and IsNumberFormat().
void SvNumberFormatter::InvalidateDateAcceptancePatterns | ( | ) |
Definition at line 3789 of file zforlist.cxx.
References pStringScanner.
|
static |
Definition at line 1310 of file zforlist.cxx.
References CURRENCY, DATE, DATETIME, DEFINED, DURATION, FRACTION, LOGICAL, NUMBER, PERCENT, SCIENTIFIC, and TIME.
Referenced by IsNumberFormat(), and SvNumberFormatsObj::isTypeCompatible().
bool SvNumberFormatter::IsDecimalSep | ( | std::u16string_view | rStr | ) | const |
Definition at line 557 of file zforlist.cxx.
References GetNumDecimalSep(), and GetNumDecimalSepAlt().
Referenced by ImpSvNumberInputScan::IsNumberFormatMain().
|
static |
Check if a specific locale has supported locale data.
Definition at line 4140 of file zforlist.cxx.
References GetTheCurrencyTable().
Referenced by SvNumberformat::SvNumberformat().
bool SvNumberFormatter::IsNatNum12 | ( | sal_uInt32 | nFIndex | ) | const |
Whether format index nFIndex has NatNum12 modifier.
Definition at line 2256 of file zforlist.cxx.
References GetFormatEntry(), GetInstanceMutex(), and SvNumberformat::GetNatNumModifierString().
bool SvNumberFormatter::IsNumberFormat | ( | const OUString & | sString, |
sal_uInt32 & | F_Index, | ||
double & | fOutNumber, | ||
SvNumInputOptions | eInputOptions = SvNumInputOptions::NONE |
||
) |
Analyze an input string.
Definition at line 1195 of file zforlist.cxx.
References ActLnge, ALL, ChangeIntl(), DATE, DATETIME, DEFINED, GetFormatEntry(), GetFormatIndex(), GetInstanceMutex(), SvNumberformat::GetLanguage(), SvNumberformat::GetMaskedType(), GetStandardFormat(), ImpSubstituteEntry(), IniLnge, IsCompatible(), NF_DATE_DIN_YYYYMMDD, NF_DATETIME_ISO_YYYYMMDD_HHMMSS, NF_DATETIME_ISO_YYYYMMDD_HHMMSS000, NF_DATETIME_ISO_YYYYMMDDTHHMMSS, NF_DATETIME_ISO_YYYYMMDDTHHMMSS000, NF_TIME_HH_MMSS, NF_TIME_HH_MMSS00, NF_TIME_MMSS00, NUMBER, pStringScanner, SV_COUNTRY_LANGUAGE_OFFSET, TEXT, and TIME.
Referenced by SvNumberFormatterServiceObj::convertStringToNumber(), and SvNumberFormatterServiceObj::detectNumberFormat().
bool SvNumberFormatter::IsSpecialStandardFormat | ( | sal_uInt32 | nFIndex, |
LanguageType | eLnge | ||
) |
Whether nFIndex is a special builtin format.
Definition at line 1490 of file zforlist.cxx.
References GetFormatIndex(), GetInstanceMutex(), NF_TIME_HH_MMSS, NF_TIME_HH_MMSS00, and NF_TIME_MMSS00.
Referenced by GetStandardFormat().
bool SvNumberFormatter::IsTextFormat | ( | sal_uInt32 | nFIndex | ) | const |
Whether format index nFIndex is of type text or not.
Definition at line 566 of file zforlist.cxx.
References GetFormatEntry(), GetInstanceMutex(), and SvNumberformat::IsTextFormat().
bool SvNumberFormatter::IsUserDefined | ( | sal_uInt32 | F_Index | ) | const |
Definition at line 3376 of file zforlist.cxx.
References DEFINED, GetFormatEntry(), GetInstanceMutex(), and SvNumberformat::GetType().
bool SvNumberFormatter::IsUserDefined | ( | std::u16string_view | sStr, |
LanguageType | eLnge = LANGUAGE_DONTKNOW |
||
) |
Check if format code string may be deleted by user.
Definition at line 3384 of file zforlist.cxx.
References ActLnge, DEFINED, GetFormatEntry(), GetInstanceMutex(), SvNumberformat::GetType(), ImpGenerateCL(), ImpIsEntry(), IniLnge, LANGUAGE_DONTKNOW, and NUMBERFORMAT_ENTRY_NOT_FOUND.
|
static |
Searches, according to the default locale currency, an entry of the CurrencyTable which is <bold>not</bold> the first (LANGUAGE_SYSTEM) entry.
Definition at line 3669 of file zforlist.cxx.
References GetTheCurrencyTable(), and nSystemCurrencyPosition.
Referenced by GetCurrencyEntry(), and ImpLookupCurrencyEntryLoopBody().
SvNumberFormatterIndexTable * SvNumberFormatter::MergeFormatter | ( | SvNumberFormatter & | rNewTable | ) |
Merge in all new entries from rNewTable and return a table of resulting new format indices.
Definition at line 3455 of file zforlist.cxx.
References aFTable, ClearMergeTable(), GetFormatEntry(), GetInstanceMutex(), SvNumberformat::GetLanguage(), SvNumberformat::GetLastInsertKey(), ImpGenerateCL(), ImpIsEntry(), nPos, NUMBERFORMAT_ENTRY_NOT_FOUND, pFormatScanner, pMergeTable, SAL_WARN, SvNumberformat::SetLastInsertKey(), SV_COUNTRY_LANGUAGE_OFFSET, SV_MAX_COUNT_STANDARD_FORMATS, and ZF_STANDARD.
bool SvNumberFormatter::PutandConvertEntry | ( | OUString & | rString, |
sal_Int32 & | nCheckPos, | ||
SvNumFormatType & | nType, | ||
sal_uInt32 & | nKey, | ||
LanguageType | eLnge, | ||
LanguageType | eNewLnge, | ||
bool | bConvertDateOrder, | ||
bool | bReplaceBooleanEquivalent = true |
||
) |
Same as <method>PutEntry</method> but the format code string is considered to be of language/country eLnge and is converted to language/country eNewLnge.
Definition at line 642 of file zforlist.cxx.
References ChangeIntl(), DEFINED, GetFormatEntry(), GetInstanceMutex(), SvNumberformat::GetType(), IniLnge, LANGUAGE_DONTKNOW, LOGICAL, nType, NUMBERFORMAT_ENTRY_NOT_FOUND, pFormatScanner, PutEntry(), and SAL_WARN.
Referenced by SvNumberFormatsObj::addNewConverted(), SvNumberformat::ConvertLanguage(), and GetFormatStringForExcel().
bool SvNumberFormatter::PutandConvertEntrySystem | ( | OUString & | rString, |
sal_Int32 & | nCheckPos, | ||
SvNumFormatType & | nType, | ||
sal_uInt32 & | nKey, | ||
LanguageType | eLnge, | ||
LanguageType | eNewLnge | ||
) |
Same as <method>PutandConvertEntry</method> but the format code string is considered to be of the System language/country eLnge and is converted to another System language/country eNewLnge.
In this case the automatic currency is converted too.
Definition at line 698 of file zforlist.cxx.
References GetInstanceMutex(), IniLnge, LANGUAGE_DONTKNOW, nType, pFormatScanner, and PutEntry().
Referenced by GetIndexPuttingAndConverting().
bool SvNumberFormatter::PutEntry | ( | OUString & | rString, |
sal_Int32 & | nCheckPos, | ||
SvNumFormatType & | nType, | ||
sal_uInt32 & | nKey, | ||
LanguageType | eLnge = LANGUAGE_DONTKNOW , |
||
bool | bReplaceBooleanEquivalent = true |
||
) |
Create new entry of a format code string for language/country.
Definition at line 574 of file zforlist.cxx.
References aFTable, ChangeIntl(), DEFINED, GetFormatEntry(), GetInstanceMutex(), SvNumberformat::GetLastInsertKey(), ImpGenerateCL(), ImpIsEntry(), IniLnge, LANGUAGE_DONTKNOW, nPos, nType, NUMBERFORMAT_ENTRY_NOT_FOUND, pFormatScanner, pStringScanner, SAL_WARN, SvNumberformat::SetLastInsertKey(), SV_COUNTRY_LANGUAGE_OFFSET, UNDEFINED, and ZF_STANDARD.
Referenced by SvNumberFormatsObj::addNew(), GetIndexPuttingAndConverting(), ImpGetDefaultCurrencyFormat(), ImpGetDefaultSystemCurrencyFormat(), PutandConvertEntry(), and PutandConvertEntrySystem().
void SvNumberFormatter::ReplaceSystemCL | ( | LanguageType | eOldLanguage | ) |
Definition at line 445 of file zforlist.cxx.
References ActLnge, aFTable, ChangeIntl(), DBG_ASSERT, DEFINED, GetFormatEntry(), ImpGenerateAdditionalFormats(), ImpGenerateFormats(), ImpGetCLOffset(), LANGUAGE_DONTKNOW, LANGUAGE_SYSTEM, m_xContext, MaxCLOffset, pFormatScanner, pStringScanner, SvNumberformat::SetLastInsertKey(), SV_COUNTRY_LANGUAGE_OFFSET, SV_MAX_COUNT_STANDARD_FORMATS, UNDEFINED, and ZF_STANDARD.
void SvNumberFormatter::ResetDefaultSystemCurrency | ( | ) |
Definition at line 3783 of file zforlist.cxx.
References nDefaultSystemCurrencyFormat, and NUMBERFORMAT_ENTRY_NOT_FOUND.
|
static |
Definition at line 3649 of file zforlist.cxx.
References bCurrencyTableInitialized, SvNumberFormatterRegistry_Impl::ConfigurationChanged(), GetFormatterRegistry(), nSystemCurrencyPosition, and SAL_INFO.
Set CallBack to ColorTable.
Definition at line 387 of file zforlist.cxx.
References aColorLink, and GetInstanceMutex().
|
static |
Set the default system currency.
The combination of abbreviation and language must match an existent element of theCurrencyTable. If not, the SYSTEM (current locale) entry becomes the default. This method is meant for the configuration of the default currency.
Definition at line 3748 of file zforlist.cxx.
References GetGlobalMutex(), GetLanguage(), SvtSysLocale::GetLanguageTag(), LanguageTag::getLanguageType(), GetTheCurrencyTable(), LANGUAGE_SYSTEM, nCount, nSystemCurrencyPosition, and NfCurrencyTable::size().
void SvNumberFormatter::SetEvalDateFormat | ( | NfEvalDateFormat | eEDF | ) |
Set evaluation type and order of input date strings.
Definition at line 3605 of file zforlist.cxx.
References eEvalDateFormat, and GetInstanceMutex().
void SvNumberFormatter::SetNoZero | ( | bool | bNZ | ) |
Set zero value suppression.
Definition at line 427 of file zforlist.cxx.
References bNoZero, and GetInstanceMutex().
Referenced by SvNumberFormatSettingsObj::setPropertyValue().
void SvNumberFormatter::SetYear2000 | ( | sal_uInt16 | nVal | ) |
Set TwoDigitYearStart, how the input string scanner handles a two digit year.
Default from VCL: 1930, 30-99 19xx, 00-29 20xx
Historically (prior to src513e) it was a two digit number determining until which number the string scanner recognizes a year to be 20xx, default <= 29 is used by SFX/OfaMiscCfg. The name Year2000 is kept although the actual functionality is now a TwoDigitYearStart which might be in any century.
Definition at line 3617 of file zforlist.cxx.
References GetInstanceMutex(), and pStringScanner.
Referenced by SvNumberFormatSettingsObj::setPropertyValue().
sal_uInt32 SvNumberFormatter::TestNewString | ( | const OUString & | sFormatString, |
LanguageType | eLnge = LANGUAGE_DONTKNOW |
||
) |
Test whether the format code string is already present in container.
Definition at line 2027 of file zforlist.cxx.
References ActLnge, ChangeIntl(), SvNumberformat::GetFormatstring(), GetInstanceMutex(), ImpGenerateCL(), ImpIsEntry(), IniLnge, LANGUAGE_DONTKNOW, NUMBERFORMAT_ENTRY_NOT_FOUND, pFormatScanner, and pStringScanner.
|
friend |
Definition at line 41 of file numformat.hxx.
Referenced by GetFormatterRegistry().
Definition at line 591 of file numformat.hxx.
Referenced by GetUserDefColor(), and SetColorLink().
|
private |
Definition at line 595 of file numformat.hxx.
Referenced by ChangeCL(), ChangeIntl(), GetEntryTable(), GetFormatSpecialInfo(), GetLangDecimalSep(), GetPreviewString(), GetPreviewStringGuess(), ImpConstruct(), ImpGenerateCL(), ImpGenerateFormats(), ImpGetDefaultCurrencyFormat(), ImpGetDefaultFormat(), ImpInsertFormat(), IsNumberFormat(), IsUserDefined(), ReplaceSystemCL(), and TestNewString().
|
private |
Definition at line 603 of file numformat.hxx.
Referenced by ChangeIntl(), GetDateSep(), and ImpConstruct().
|
private |
Definition at line 600 of file numformat.hxx.
Referenced by ChangeIntl(), GetNumDecimalSep(), and ImpConstruct().
|
private |
Definition at line 601 of file numformat.hxx.
Referenced by ChangeIntl(), GetNumDecimalSepAlt(), and ImpConstruct().
|
private |
Definition at line 580 of file numformat.hxx.
Referenced by ImpGetDefaultCurrencyFormat(), and ImpGetDefaultFormat().
|
private |
Definition at line 578 of file numformat.hxx.
Referenced by DeleteEntry(), GetEntry(), GetEntryTable(), GetFormatEntry(), ImpGenerateFormats(), ImpGetDefaultCurrencyFormat(), ImpGetDefaultFormat(), ImpInsertFormat(), ImpIsEntry(), ImpSubstituteEntry(), MergeFormatter(), PutEntry(), ReplaceSystemCL(), and ~SvNumberFormatter().
|
private |
Definition at line 602 of file numformat.hxx.
Referenced by ChangeIntl(), GetNumThousandSep(), and ImpConstruct().
|
staticprivate |
Definition at line 605 of file numformat.hxx.
Referenced by GetTheCurrencyTable(), ImpInitCurrencyTable(), and resetTheCurrencyTable().
|
private |
Definition at line 597 of file numformat.hxx.
Referenced by GetNoZero(), GetOutputString(), ImpConstruct(), and SetNoZero().
|
private |
Definition at line 596 of file numformat.hxx.
Referenced by GetEvalDateFormat(), ImpConstruct(), and SetEvalDateFormat().
|
private |
Definition at line 594 of file numformat.hxx.
Referenced by GenerateFormat(), GetEntryKey(), GetFirstEntryTable(), GetFormatForLanguageIfBuiltIn(), GetFormatIndex(), GetFormatSpecialInfo(), GetKeywords(), GetLanguage(), GetPreviewString(), GetPreviewStringGuess(), GetStandardFormat(), GetStandardIndex(), ImpConstruct(), IsNumberFormat(), IsUserDefined(), PutandConvertEntry(), PutandConvertEntrySystem(), PutEntry(), and TestNewString().
|
static |
Precision suitable for numbers displayed in input bar, for instance Calc's formula input bar.
Definition at line 54 of file numformat.hxx.
Referenced by GetInputLineString(), SvNumberformat::GetOutputString(), SvNumberformat::ImpGetDateTimeOutput(), and SvNumberformat::ImpGetTimeOutput().
|
private |
Definition at line 574 of file numformat.hxx.
|
private |
Definition at line 575 of file numformat.hxx.
Referenced by ChangeIntl(), GetComponentContext(), ImpConstruct(), ImpGenerateFormats(), and ReplaceSystemCL().
|
private |
Definition at line 576 of file numformat.hxx.
Referenced by ChangeIntl(), GetLanguageTag(), ImpConstruct(), ImpGenerateCL(), and ImpInsertFormat().
|
private |
Definition at line 592 of file numformat.hxx.
Referenced by GetUsedLanguages(), ImpConstruct(), ImpGenerateCL(), ImpGetCLOffset(), and ReplaceSystemCL().
|
private |
Definition at line 593 of file numformat.hxx.
Referenced by ImpConstruct(), ImpGetDefaultSystemCurrencyFormat(), and ResetDefaultSystemCurrency().
|
staticprivate |
Definition at line 606 of file numformat.hxx.
Referenced by ImpInitCurrencyTable(), MatchSystemCurrency(), resetTheCurrencyTable(), and SetDefaultSystemCurrency().
|
private |
Definition at line 590 of file numformat.hxx.
Referenced by ChangeIntl(), ChangeNullDate(), ChangeStandardPrec(), FillKeywordTable(), GenerateFormat(), GetCurrencyFormatStrings(), GetFormatPrecision(), GetFormatScanner(), GetFormatSpecialInfo(), GetInputLineString(), GetKeyword(), GetKeywords(), GetNullDate(), GetPreviewString(), GetPreviewStringGuess(), GetStandardName(), GetStandardPrec(), ImpConstruct(), ImpGenerateFormats(), ImpInsertFormat(), MergeFormatter(), PutandConvertEntry(), PutandConvertEntrySystem(), PutEntry(), ReplaceSystemCL(), and TestNewString().
|
private |
Definition at line 581 of file numformat.hxx.
Referenced by GetEntryTable(), and ImpConstruct().
|
staticprivate |
Definition at line 607 of file numformat.hxx.
Referenced by GetFormatterRegistry(), and ~SvNumberFormatter().
|
private |
Definition at line 583 of file numformat.hxx.
Referenced by ClearMergeTable(), ConvertMergeTableToMap(), GetMergeFormatIndex(), HasMergeFormatTable(), ImpConstruct(), and MergeFormatter().
|
private |
Definition at line 589 of file numformat.hxx.
Referenced by ChangeIntl(), ChangeNullDate(), ExpandTwoDigitYear(), GetFormatSpecialInfo(), GetPreviewString(), GetPreviewStringGuess(), GetYear2000(), ImpConstruct(), ImpGenerateFormats(), ImpInsertFormat(), InvalidateDateAcceptancePatterns(), IsNumberFormat(), PutEntry(), ReplaceSystemCL(), SetYear2000(), and TestNewString().
|
static |
We can't technically have an "infinite" value, so we use an arbitrary upper precision threshold to represent the "unlimited" precision.
Definition at line 48 of file numformat.hxx.
Referenced by SvNumberformat::GetOutputString(), and SvNumberformat::GetThousandDivisorPrecision().
|
private |
Definition at line 587 of file numformat.hxx.
Referenced by ChangeIntl(), GetCalendar(), and ImpConstruct().
|
private |
Definition at line 584 of file numformat.hxx.
Referenced by ChangeIntl(), GetCharClass(), GetPreviewStringGuess(), and ImpConstruct().
|
private |
Definition at line 585 of file numformat.hxx.
Referenced by ChangeIntl(), GenerateFormat(), GetCompatibilityCurrency(), GetCurrencyFormatStrings(), GetLangDecimalSep(), GetLocaleData(), ImpAdjustFormatCodeDefault(), ImpConstruct(), ImpGenerateCL(), ImpGenerateFormats(), ImpGetFormatCodeIndex(), and ImpInsertFormat().
|
private |
Definition at line 588 of file numformat.hxx.
Referenced by GetNatNum(), and ImpConstruct().
|
private |
Definition at line 586 of file numformat.hxx.
Referenced by ChangeIntl(), GetPreviewStringGuess(), GetTransliteration(), and ImpConstruct().