[Libreoffice-commits] .: vcl/generic
Caolán McNamara
caolan at kemper.freedesktop.org
Sat Jul 14 10:36:58 PDT 2012
vcl/generic/glyphs/gcach_layout.cxx | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
New commits:
commit 938824ca84c46ca1a1b627a94d95ba8b24f26b65
Author: Caolán McNamara <caolanm at redhat.com>
Date: Sat Jul 14 18:33:04 2012 +0100
Related: fdo#31821 prefer non-latn over latn, but latn over nothing
Change-Id: I00d4b7bdd6c35ab72ef57c3889fa4c5a7a464e05
diff --git a/vcl/generic/glyphs/gcach_layout.cxx b/vcl/generic/glyphs/gcach_layout.cxx
index fa51e62..db04bdb 100644
--- a/vcl/generic/glyphs/gcach_layout.cxx
+++ b/vcl/generic/glyphs/gcach_layout.cxx
@@ -422,9 +422,13 @@ bool IcuLayoutEngine::operator()( ServerFontLayout& rLayout, ImplLayoutArgs& rAr
le_int32 eScriptCode = -1;
for( int i = nMinRunPos; i < nEndRunPos; ++i )
{
- eScriptCode = uscript_getScript( pIcuChars[i], &rcI18n );
- if( (eScriptCode > 0) && (eScriptCode != latnScriptCode) )
- break;
+ le_int32 eNextScriptCode = uscript_getScript( pIcuChars[i], &rcI18n );
+ if( (eNextScriptCode > USCRIPT_INHERITED) )
+ {
+ eScriptCode = eNextScriptCode;
+ if (eNextScriptCode != latnScriptCode)
+ break;
+ }
}
if( eScriptCode < 0 ) // TODO: handle errors better
eScriptCode = latnScriptCode;
More information about the Libreoffice-commits
mailing list