22#include <com/sun/star/i18n/MultipleCharsOutputException.hpp>
33fullwidthToHalfwidth::fullwidthToHalfwidth()
36 table = &i18nutil::widthfolding::getfull2halfTable();
37 transliterationName =
"fullwidthToHalfwidth";
47fullwidthToHalfwidth::transliterateImpl(
const OUString& inStr, sal_Int32 startPos, sal_Int32 nCount,
Sequence< sal_Int32 >* pOffset )
50 const OUString& newStr = i18nutil::widthfolding::decompose_ja_voiced_sound_marks (inStr, startPos, nCount, pOffset);
57fullwidthToHalfwidth::transliterateChar2Char(
sal_Unicode inChar)
59 sal_Unicode newChar = i18nutil::widthfolding::decompose_ja_voiced_sound_marksChar2Char (inChar);
60 if (newChar == 0xFFFF)
61 throw MultipleCharsOutputException();
65FULLWIDTHKATAKANA_HALFWIDTHKATAKANA::FULLWIDTHKATAKANA_HALFWIDTHKATAKANA()
68 table = &i18nutil::widthfolding::getfullKana2halfKanaTable();
69 transliterationName =
"fullwidthKatakanaToHalfwidthKatakana";
70 implementationName =
"com.sun.star.i18n.Transliteration.FULLWIDTHKATAKANA_HALFWIDTHKATAKANA";
77FULLWIDTHKATAKANA_HALFWIDTHKATAKANA::transliterateImpl(
const OUString& inStr, sal_Int32 startPos, sal_Int32 nCount,
Sequence< sal_Int32 >* pOffset )
80 const OUString& newStr = i18nutil::widthfolding::decompose_ja_voiced_sound_marks (inStr, startPos, nCount, pOffset);
87FULLWIDTHKATAKANA_HALFWIDTHKATAKANA::transliterateChar2Char(
sal_Unicode inChar )
89 sal_Unicode newChar = i18nutil::widthfolding::decompose_ja_voiced_sound_marksChar2Char (inChar);
90 if (newChar == 0xFFFF)
91 throw MultipleCharsOutputException();
95FULLWIDTH_HALFWIDTH_LIKE_ASC::FULLWIDTH_HALFWIDTH_LIKE_ASC()
98 table = &i18nutil::widthfolding::getfull2halfTableForASC();
99 transliterationName =
"fullwidthToHalfwidthLikeASC";
100 implementationName =
"com.sun.star.i18n.Transliteration.FULLWIDTH_HALFWIDTH_LIKE_ASC";
107FULLWIDTH_HALFWIDTH_LIKE_ASC::transliterateImpl(
const OUString& inStr, sal_Int32 startPos, sal_Int32 nCount,
Sequence< sal_Int32 >* pOffset )
110 const OUString& newStr = i18nutil::widthfolding::decompose_ja_voiced_sound_marks (inStr, startPos, nCount, pOffset);
117FULLWIDTH_HALFWIDTH_LIKE_ASC::transliterateChar2Char(
sal_Unicode inChar )
119 sal_Unicode newChar = i18nutil::widthfolding::decompose_ja_voiced_sound_marksChar2Char (inChar);
120 if (newChar == 0xFFFF)
121 throw MultipleCharsOutputException();
sal_Unicode SAL_CALL transliterateChar2Char(sal_Unicode inChar) override
OUString transliterateImpl(const OUString &inStr, sal_Int32 startPos, sal_Int32 nCount, css::uno::Sequence< sal_Int32 > *pOffset) override
Constant values shared between i18npool and, for example, the number formatter.
constexpr OUStringLiteral implementationName