From 594bf9e60a69184fdfaa3b9a0ac4206a2a793576 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Mon, 19 Aug 2019 13:23:35 +0100 Subject: use double prime symbol for inch MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: I8565bbe8a72ee748676f673239725e5eb4f3ed6f Reviewed-on: https://gerrit.libreoffice.org/77718 Tested-by: Jenkins Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara --- vcl/source/control/field.cxx | 5 ++++- vcl/source/window/builder.cxx | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) (limited to 'vcl') diff --git a/vcl/source/control/field.cxx b/vcl/source/control/field.cxx index fadd02f7eeae..7387a2996f05 100644 --- a/vcl/source/control/field.cxx +++ b/vcl/source/control/field.cxx @@ -1389,8 +1389,11 @@ OUString MetricFormatter::CreateFieldText( sal_Int64 nValue ) const aStr += " "; if (meUnit == FieldUnit::INCH) { - if (aSuffix != "\"") + OUString sDoublePrime = u"\u2033"; + if (aSuffix != "\"" && aSuffix != sDoublePrime) aStr += " "; + else + aSuffix = sDoublePrime; } assert(meUnit != FieldUnit::PERCENT); aStr += aSuffix; diff --git a/vcl/source/window/builder.cxx b/vcl/source/window/builder.cxx index 502ae061367f..09c9a9a900a3 100644 --- a/vcl/source/window/builder.cxx +++ b/vcl/source/window/builder.cxx @@ -247,8 +247,11 @@ namespace weld aStr += " "; if (m_eSrcUnit == FieldUnit::INCH) { - if (aSuffix != "\"") + OUString sDoublePrime = u"\u2033"; + if (aSuffix != "\"" && aSuffix != sDoublePrime) aStr += " "; + else + aSuffix = sDoublePrime; } assert(m_eSrcUnit != FieldUnit::PERCENT); aStr += aSuffix; -- cgit