summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorLaurent Balland-Poirier <laurent.balland-poirier@laposte.net>2017-02-16 22:15:37 +0100
committerEike Rathke <erack@redhat.com>2017-02-21 12:31:50 +0000
commite7f769bc67d3f132b477b3c253f8065243b9b8ac (patch)
treeb86d8c82e96c0c8cae0319d9ed4f167a8d9a7ba2 /sc
parent291c9122b23ce7aa619e828b895b08dcd21bf025 (diff)
tdf#106052 Treat SubFormat for "Precision as shown"
Get precision from the correct subformat Change-Id: I458e5b3d1fb515864f19499ac9ac529e1d68a267 Reviewed-on: https://gerrit.libreoffice.org/34505 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Eike Rathke <erack@redhat.com>
Diffstat (limited to 'sc')
-rw-r--r--sc/source/core/data/documen4.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/sc/source/core/data/documen4.cxx b/sc/source/core/data/documen4.cxx
index fed6c0d043f0..6a1110b6cd80 100644
--- a/sc/source/core/data/documen4.cxx
+++ b/sc/source/core/data/documen4.cxx
@@ -660,7 +660,7 @@ double ScDocument::RoundValueAsShown( double fVal, sal_uInt32 nFormat ) const
short nPrecision;
if ((nFormat % SV_COUNTRY_LANGUAGE_OFFSET) != 0)
{
- nPrecision = (short)pFormat->GetFormatPrecision();
+ nPrecision = (short)GetFormatTable()->GetFormatPrecision( nFormat, fVal );
switch ( nType )
{
case css::util::NumberFormat::PERCENT: // 0.41% == 0.0041