Fix performence problem while shaping a lines with many scripts
Fix quadradic behaviour regression introduced in commit
2e6b8b4734
Task-number: QTBUG-22275
Change-Id: I343452c6b1cd0e571770e5dadd3cd6fd3167c96d
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
This commit is contained in:
parent
c13011829f
commit
b1e082ec9f
@ -884,7 +884,7 @@ HB_Bool HB_SelectScript(HB_ShaperItem *shaper_item, const HB_OpenTypeFeature *fe
|
||||
|
||||
static HB_Bool containsSurrogates(HB_ShaperItem *item)
|
||||
{
|
||||
for (hb_uint32 i=0; i<item->stringLength; ++i) {
|
||||
for (hb_uint32 i=item->item.pos; i<item->item.pos+item->item.length; ++i) {
|
||||
HB_UChar16 ucs = item->string[i];
|
||||
if ( HB_IsHighSurrogate(ucs) || HB_IsLowSurrogate(ucs) )
|
||||
return true;
|
||||
|
Loading…
Reference in New Issue
Block a user