summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolan.mcnamara@collabora.com>2024-03-13 12:13:54 +0000
committerCaolán McNamara <caolan.mcnamara@collabora.com>2024-03-13 21:41:19 +0100
commit07872404ccfc99324b81b17bb90f1dc624b234fb (patch)
treede45e8ba0e45f7a680304179f1f43a318c4d2ae6
parent848ed64cd5b63f07d11bf3754c522a731fa7ae88 (diff)
These methods can be const too
Change-Id: Iaef46216dac6584f57b7933d658384f54d0a4544 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/164772 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
-rw-r--r--include/svl/zformat.hxx8
-rw-r--r--svl/source/numbers/zformat.cxx8
2 files changed, 8 insertions, 8 deletions
diff --git a/include/svl/zformat.hxx b/include/svl/zformat.hxx
index 9b584ad5877d..b4d7ddb0ac29 100644
--- a/include/svl/zformat.hxx
+++ b/include/svl/zformat.hxx
@@ -638,7 +638,7 @@ private:
sal_uInt16 j,
sal_uInt16 nIx,
sal_Int32 nDigCnt,
- bool bAddDecSep = true );
+ bool bAddDecSep = true ) const;
// Helper function to fill in the group (AKA thousand) separators
// or to skip additional digits
@@ -647,14 +647,14 @@ private:
sal_Int32& k,
sal_uInt16 nIx,
sal_Int32 & nDigitCount,
- utl::DigitGroupingIterator & );
+ utl::DigitGroupingIterator & ) const;
SVL_DLLPRIVATE bool ImpDecimalFill( OUStringBuffer& sStr,
double& rNumber,
sal_Int32 nDecPos,
sal_uInt16 j,
sal_uInt16 nIx,
- bool bInteger );
+ bool bInteger ) const;
/** Calculate each element of fraction:
* integer part, numerator part, denominator part
@@ -705,7 +705,7 @@ private:
SVL_DLLPRIVATE bool ImpGetNumberOutput( double fNumber,
sal_uInt16 nIx,
- OUStringBuffer& OutString );
+ OUStringBuffer& OutString ) const;
SVL_DLLPRIVATE void ImpCopyNumberformat( const SvNumberformat& rFormat );
diff --git a/svl/source/numbers/zformat.cxx b/svl/source/numbers/zformat.cxx
index 3948c5f70206..062f86fe4c59 100644
--- a/svl/source/numbers/zformat.cxx
+++ b/svl/source/numbers/zformat.cxx
@@ -4352,7 +4352,7 @@ bool SvNumberformat::ImpGetLogicalOutput(double fNumber,
bool SvNumberformat::ImpGetNumberOutput(double fNumber,
sal_uInt16 nIx,
- OUStringBuffer& sStr)
+ OUStringBuffer& sStr) const
{
bool bRes = false;
bool bSign;
@@ -4470,7 +4470,7 @@ bool SvNumberformat::ImpDecimalFill( OUStringBuffer& sStr, // number string
sal_Int32 nDecPos, // decimals start
sal_uInt16 j, // symbol index within format code
sal_uInt16 nIx, // subformat index
- bool bInteger) // is integer
+ bool bInteger) const // is integer
{
bool bRes = false;
bool bFilled = false; // Was filled?
@@ -4592,7 +4592,7 @@ bool SvNumberformat::ImpNumberFillWithThousands( OUStringBuffer& sBuff, // numb
sal_uInt16 j, // symbol index within format code
sal_uInt16 nIx, // subformat index
sal_Int32 nDigCnt, // count of integer digits in format
- bool bAddDecSep) // add decimal separator if necessary
+ bool bAddDecSep) const // add decimal separator if necessary
{
bool bRes = false;
sal_Int32 nLeadingStringChars = 0; // inserted StringChars before number
@@ -4752,7 +4752,7 @@ void SvNumberformat::ImpDigitFill(OUStringBuffer& sStr, // number string
sal_Int32 & k, // position within string
sal_uInt16 nIx, // subformat index
sal_Int32 & nDigitCount, // count of integer digits from the right so far
- utl::DigitGroupingIterator & rGrouping ) // current grouping
+ utl::DigitGroupingIterator & rGrouping ) const // current grouping
{
if (NumFor[nIx].Info().bThousand) // Only if grouping fill in separators
{