Fix QTextEngine::shapeText casing of surrogate pairs
The high part was not copied to output. Fixes: QTBUG-75559 Change-Id: I9350e52d256510f52b3fcc0015bf879d2c609532 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>bb10
parent
6afdbfdaaf
commit
b5154b5254
|
|
@ -1383,11 +1383,12 @@ void QTextEngine::shapeText(int item) const
|
|||
if (QChar::isHighSurrogate(ucs4) && i + 1 < itemLength) {
|
||||
uint low = string[i + 1];
|
||||
if (QChar::isLowSurrogate(low)) {
|
||||
// high part never changes in simple casing
|
||||
uc[i] = ucs4;
|
||||
++i;
|
||||
ucs4 = QChar::surrogateToUcs4(ucs4, low);
|
||||
ucs4 = si.analysis.flags == QScriptAnalysis::Lowercase ? QChar::toLower(ucs4)
|
||||
: QChar::toUpper(ucs4);
|
||||
// high part never changes in simple casing
|
||||
uc[i] = QChar::lowSurrogate(ucs4);
|
||||
}
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Reference in New Issue