From 6d15d4a6f6fbc163001ec082d55404481e64bed1 Mon Sep 17 00:00:00 2001 From: Tor Lillqvist Date: Sun, 12 Feb 2017 12:55:00 +0200 Subject: Get rid of "unicodes" in lower-case, too Instead, use "code points" (if you mean full 21-bit Unicode code points), or "code units" (if you mean the 16-bit units that make up UTF-16). Hopefully I got it right which one was meant in each case here. Change-Id: I8ee7a98996f1cebcfb95cd7d18a56570e48fa390 --- vcl/unx/generic/fontmanager/fontconfig.cxx | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'vcl/unx/generic/fontmanager/fontconfig.cxx') diff --git a/vcl/unx/generic/fontmanager/fontconfig.cxx b/vcl/unx/generic/fontmanager/fontconfig.cxx index 9a58e91037a4..120a116bcfb4 100644 --- a/vcl/unx/generic/fontmanager/fontconfig.cxx +++ b/vcl/unx/generic/fontmanager/fontconfig.cxx @@ -948,12 +948,12 @@ void PrintFontManager::Substitute( FontSelectPattern &rPattern, OUString& rMissi // Add required Unicode characters, if any if ( !rMissingCodes.isEmpty() ) { - FcCharSet *unicodes = FcCharSetCreate(); + FcCharSet *codePoints = FcCharSetCreate(); for( sal_Int32 nStrIndex = 0; nStrIndex < rMissingCodes.getLength(); ) { // also handle unicode surrogates const sal_uInt32 nCode = rMissingCodes.iterateCodePoints( &nStrIndex ); - FcCharSetAddChar( unicodes, nCode ); + FcCharSetAddChar( codePoints, nCode ); //if the codepoint is impossible for this lang tag, then clear it //and autodetect something useful if (!aLangAttrib.isEmpty() && isImpossibleCodePointForLang(aLangTag, nCode)) @@ -965,8 +965,8 @@ void PrintFontManager::Substitute( FontSelectPattern &rPattern, OUString& rMissi aLangAttrib = mapToFontConfigLangTag(aLangTag); } } - FcPatternAddCharSet(pPattern, FC_CHARSET, unicodes); - FcCharSetDestroy(unicodes); + FcPatternAddCharSet(pPattern, FC_CHARSET, codePoints); + FcCharSetDestroy(codePoints); } if (!aLangAttrib.isEmpty()) @@ -1065,19 +1065,19 @@ void PrintFontManager::Substitute( FontSelectPattern &rPattern, OUString& rMissi } } - // update rMissingCodes by removing resolved unicodes + // update rMissingCodes by removing resolved code points if( !rMissingCodes.isEmpty() ) { std::unique_ptr const pRemainingCodes(new sal_uInt32[rMissingCodes.getLength()]); int nRemainingLen = 0; - FcCharSet* unicodes; - if (!FcPatternGetCharSet(pSet->fonts[0], FC_CHARSET, 0, &unicodes)) + FcCharSet* codePoints; + if (!FcPatternGetCharSet(pSet->fonts[0], FC_CHARSET, 0, &codePoints)) { for( sal_Int32 nStrIndex = 0; nStrIndex < rMissingCodes.getLength(); ) { - // also handle unicode surrogates + // also handle surrogates const sal_uInt32 nCode = rMissingCodes.iterateCodePoints( &nStrIndex ); - if (FcCharSetHasChar(unicodes, nCode) != FcTrue) + if (FcCharSetHasChar(codePoints, nCode) != FcTrue) pRemainingCodes[ nRemainingLen++ ] = nCode; } } -- cgit