From 3729f11336c21a4273c18da9bf2891c69a9489be Mon Sep 17 00:00:00 2001 From: Tor Lillqvist Date: Fri, 16 Nov 2018 00:54:14 +0200 Subject: Swiss Standard German: replace 'ß' in German translation with 'ss' MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit In this branch, for iOS only. Change-Id: I2af12394648ddad352f24c71581be0f9bf5e3d70 --- unotools/source/i18n/resmgr.cxx | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'unotools') diff --git a/unotools/source/i18n/resmgr.cxx b/unotools/source/i18n/resmgr.cxx index 4159cc670f81..ad75a3ed612f 100644 --- a/unotools/source/i18n/resmgr.cxx +++ b/unotools/source/i18n/resmgr.cxx @@ -200,7 +200,15 @@ namespace Translate //otherwise translate it const std::string ret = boost::locale::pgettext(sContext.getStr(), pId, loc); - return ExpandVariables(createFromUtf8(ret.data(), ret.size())); + OUString result(ExpandVariables(createFromUtf8(ret.data(), ret.size()))); + +#ifdef IOS + // If it is de-CH, change sharp s to double s. + if (std::use_facet(loc).country() == "CH" && + std::use_facet(loc).language() == "de") + result = result.replaceAll(OUString::fromUtf8("\xC3\x9F"), "ss"); +#endif + return result; } static ResHookProc pImplResHookProc = nullptr; -- cgit