diff options
author | Tor Lillqvist <tml@collabora.com> | 2018-11-16 00:54:14 +0200 |
---|---|---|
committer | Tor Lillqvist <tml@collabora.com> | 2019-09-19 18:16:14 +0200 |
commit | d5036afc69b45985fcacb0bb48eae3fe9242ceeb (patch) | |
tree | 86b3c11c369ae502b7916a5b9cc311f12a4d6e7c /unotools/source | |
parent | 2b09926c939187097c66321ab9026eee4c726aa5 (diff) |
Swiss Standard German: replace 'ß' in German translation with 'ss'
In this branch, for iOS only.
Change-Id: I2af12394648ddad352f24c71581be0f9bf5e3d70
Reviewed-on: https://gerrit.libreoffice.org/79134
Reviewed-by: Tor Lillqvist <tml@collabora.com>
Tested-by: Tor Lillqvist <tml@collabora.com>
Diffstat (limited to 'unotools/source')
-rw-r--r-- | unotools/source/i18n/resmgr.cxx | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/unotools/source/i18n/resmgr.cxx b/unotools/source/i18n/resmgr.cxx index 8d4fcb5eac33..7649e94abe4c 100644 --- a/unotools/source/i18n/resmgr.cxx +++ b/unotools/source/i18n/resmgr.cxx @@ -243,7 +243,15 @@ namespace Translate //otherwise translate it const std::string ret = boost::locale::npgettext(aContextIdId[0].getStr(), aContextIdId[1].getStr(), aContextIdId[2].getStr(), n, 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<boost::locale::info>(loc).country() == "CH" && + std::use_facet<boost::locale::info>(loc).language() == "de") + result = result.replaceAll(OUString::fromUtf8("\xC3\x9F"), "ss"); +#endif + return result; } static ResHookProc pImplResHookProc = nullptr; |