diff options
-rw-r--r-- | i18nutil/source/utility/casefolding.cxx | 2 | ||||
-rw-r--r-- | i18nutil/source/utility/unicode.cxx | 4 | ||||
-rw-r--r-- | i18nutil/source/utility/widthfolding.cxx | 10 | ||||
-rw-r--r-- | include/i18nutil/unicode.hxx | 18 | ||||
-rw-r--r-- | include/i18nutil/widthfolding.hxx | 4 |
5 files changed, 19 insertions, 19 deletions
diff --git a/i18nutil/source/utility/casefolding.cxx b/i18nutil/source/utility/casefolding.cxx index c0f58d3464b5..cbe7ea91b833 100644 --- a/i18nutil/source/utility/casefolding.cxx +++ b/i18nutil/source/utility/casefolding.cxx @@ -108,7 +108,7 @@ Mapping& casefolding::getValue(const sal_Unicode* str, sal_Int32 pos, sal_Int32 return dummy; } -inline sal_Bool SAL_CALL +inline bool SAL_CALL is_ja_voice_sound_mark(sal_Unicode& current, sal_Unicode next) { sal_Unicode c = 0; diff --git a/i18nutil/source/utility/unicode.cxx b/i18nutil/source/utility/unicode.cxx index ff928053d8c2..edea19846742 100644 --- a/i18nutil/source/utility/unicode.cxx +++ b/i18nutil/source/utility/unicode.cxx @@ -378,7 +378,7 @@ unicode::getUnicodeDirection( const sal_Unicode ch ) { bit(UnicodeType::PARAGRAPH_SEPARATOR) #define IsType(func, mask) \ -sal_Bool SAL_CALL func( const sal_Unicode ch) {\ +bool SAL_CALL func( const sal_Unicode ch) {\ return (bit(getUnicodeType(ch)) & (mask)) != 0;\ } @@ -389,7 +389,7 @@ IsType(unicode::isSpace, SPACEMASK) #define CONTROLSPACE bit(0x09)|bit(0x0a)|bit(0x0b)|bit(0x0c)|bit(0x0d)|\ bit(0x1c)|bit(0x1d)|bit(0x1e)|bit(0x1f) -sal_Bool SAL_CALL unicode::isWhiteSpace( const sal_Unicode ch) { +bool SAL_CALL unicode::isWhiteSpace( const sal_Unicode ch) { return (ch != 0xa0 && isSpace(ch)) || (ch <= 0x1F && (bit(ch) & (CONTROLSPACE))); } diff --git a/i18nutil/source/utility/widthfolding.cxx b/i18nutil/source/utility/widthfolding.cxx index a7ecb98052b4..2d3fcb1a93c9 100644 --- a/i18nutil/source/utility/widthfolding.cxx +++ b/i18nutil/source/utility/widthfolding.cxx @@ -41,7 +41,7 @@ sal_Unicode widthfolding::decompose_ja_voiced_sound_marksChar2Char (sal_Unicode /** * Decompose Japanese specific voiced and semi-voiced sound marks. */ -OUString widthfolding::decompose_ja_voiced_sound_marks (const OUString& inStr, sal_Int32 startPos, sal_Int32 nCount, Sequence< sal_Int32 >& offset, sal_Bool useOffset ) +OUString widthfolding::decompose_ja_voiced_sound_marks (const OUString& inStr, sal_Int32 startPos, sal_Int32 nCount, Sequence< sal_Int32 >& offset, bool useOffset ) { // Create a string buffer which can hold nCount * 2 + 1 characters. // Its size may become double of nCount. @@ -103,7 +103,7 @@ oneToOneMapping& widthfolding::getfull2halfTable(void) /** * Compose Japanese specific voiced and semi-voiced sound marks. */ -OUString widthfolding::compose_ja_voiced_sound_marks (const OUString& inStr, sal_Int32 startPos, sal_Int32 nCount, Sequence< sal_Int32 >& offset, sal_Bool useOffset, sal_Int32 nFlags ) +OUString widthfolding::compose_ja_voiced_sound_marks (const OUString& inStr, sal_Int32 startPos, sal_Int32 nCount, Sequence< sal_Int32 >& offset, bool useOffset, sal_Int32 nFlags ) { // Create a string buffer which can hold nCount + 1 characters. // Its size may become equal to nCount or smaller. @@ -157,14 +157,14 @@ OUString widthfolding::compose_ja_voiced_sound_marks (const OUString& inStr, sal // 0 addresses a code point regarding 0x3099 or 0x309b (voiced sound mark), // 1 is 0x309a or 0x309c (semi-voiced sound mark) int i = int(previousChar - 0x3040); // i acts as an index of array - sal_Bool bCompose = sal_False; + bool bCompose = false; if (0 <= i && i <= (0x30ff - 0x3040) && composition_table[i][j]) - bCompose = sal_True; + bCompose = true; // not to use combined KATAKANA LETTER VU if ( previousChar == 0x30a6 && (nFlags & WIDTHFOLDNIG_DONT_USE_COMBINED_VU) ) - bCompose = sal_False; + bCompose = false; if( bCompose ){ if (useOffset) { diff --git a/include/i18nutil/unicode.hxx b/include/i18nutil/unicode.hxx index e3210390e2eb..64aa2a9bc096 100644 --- a/include/i18nutil/unicode.hxx +++ b/include/i18nutil/unicode.hxx @@ -41,15 +41,15 @@ public: static sal_Unicode SAL_CALL getUnicodeScriptStart(com::sun::star::i18n::UnicodeScript type); static sal_Unicode SAL_CALL getUnicodeScriptEnd(com::sun::star::i18n::UnicodeScript type); static sal_uInt8 SAL_CALL getUnicodeDirection( const sal_Unicode ch ); - static sal_Bool SAL_CALL isUpper( const sal_Unicode ch); - static sal_Bool SAL_CALL isLower( const sal_Unicode ch); - static sal_Bool SAL_CALL isDigit( const sal_Unicode ch); - static sal_Bool SAL_CALL isControl( const sal_Unicode ch); - static sal_Bool SAL_CALL isPrint( const sal_Unicode ch); - static sal_Bool SAL_CALL isAlpha( const sal_Unicode ch); - static sal_Bool SAL_CALL isSpace( const sal_Unicode ch); - static sal_Bool SAL_CALL isWhiteSpace( const sal_Unicode ch); - static sal_Bool SAL_CALL isAlphaDigit( const sal_Unicode ch); + static bool SAL_CALL isUpper( const sal_Unicode ch); + static bool SAL_CALL isLower( const sal_Unicode ch); + static bool SAL_CALL isDigit( const sal_Unicode ch); + static bool SAL_CALL isControl( const sal_Unicode ch); + static bool SAL_CALL isPrint( const sal_Unicode ch); + static bool SAL_CALL isAlpha( const sal_Unicode ch); + static bool SAL_CALL isSpace( const sal_Unicode ch); + static bool SAL_CALL isWhiteSpace( const sal_Unicode ch); + static bool SAL_CALL isAlphaDigit( const sal_Unicode ch); //Map an ISO 15924 script code to Latin/Asian/Complex/Weak static sal_Int16 SAL_CALL getScriptClassFromUScriptCode(UScriptCode eScript); diff --git a/include/i18nutil/widthfolding.hxx b/include/i18nutil/widthfolding.hxx index ccd1a1b5273a..4987ffddd233 100644 --- a/include/i18nutil/widthfolding.hxx +++ b/include/i18nutil/widthfolding.hxx @@ -40,9 +40,9 @@ public: static oneToOneMapping& getfullKana2halfKanaTable(); static oneToOneMapping& gethalfKana2fullKanaTable(); - static OUString decompose_ja_voiced_sound_marks(const OUString& inStr, sal_Int32 startPos, sal_Int32 nCount, com::sun::star::uno::Sequence< sal_Int32 >& offset, sal_Bool useOffset); + static OUString decompose_ja_voiced_sound_marks(const OUString& inStr, sal_Int32 startPos, sal_Int32 nCount, com::sun::star::uno::Sequence< sal_Int32 >& offset, bool useOffset); static sal_Unicode decompose_ja_voiced_sound_marksChar2Char (sal_Unicode inChar); - static OUString compose_ja_voiced_sound_marks(const OUString& inStr, sal_Int32 startPos, sal_Int32 nCount, com::sun::star::uno::Sequence< sal_Int32 >& offset, sal_Bool useOffset, sal_Int32 nFlags = 0 ); + static OUString compose_ja_voiced_sound_marks(const OUString& inStr, sal_Int32 startPos, sal_Int32 nCount, com::sun::star::uno::Sequence< sal_Int32 >& offset, bool useOffset, sal_Int32 nFlags = 0 ); static sal_Unicode getCompositionChar(sal_Unicode c1, sal_Unicode c2); }; |