diff options
author | Konstantin Ritt <ritt.ks@gmail.com> | 2020-03-18 05:36:49 +0300 |
---|---|---|
committer | Konstantin Ritt <ritt.ks@gmail.com> | 2020-03-24 01:57:09 +0300 |
commit | 12d3d32f31182f1eb395ec9e5fa1874d06e2582b (patch) | |
tree | 24a020e176cf4574f142879ba284a5a0bd819ef1 | |
parent | c14f3deca91eb6e7ab23f5f73004f4f824b97d95 (diff) |
QTextEngine: stop guessing the same language in a loop
Change-Id: I155b9380a4ff412d59c7939c377d20f4783e4730
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
-rw-r--r-- | src/gui/text/qtextengine.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gui/text/qtextengine.cpp b/src/gui/text/qtextengine.cpp index ce14793858..fa0352514b 100644 --- a/src/gui/text/qtextengine.cpp +++ b/src/gui/text/qtextengine.cpp @@ -1626,7 +1626,8 @@ int QTextEngine::shapeTextWithHarfbuzzNG(const QScriptItem &si, props.direction = si.analysis.bidiLevel % 2 ? HB_DIRECTION_RTL : HB_DIRECTION_LTR; QChar::Script script = QChar::Script(si.analysis.script); props.script = hb_qt_script_to_script(script); - // ### props.language = hb_language_get_default_for_script(props.script); + // ### TODO get_default_for_script? + props.language = hb_language_get_default(); // use default language from locale for (int k = 0; k < itemBoundaries.size(); k += 3) { const uint item_pos = itemBoundaries[k]; @@ -1656,7 +1657,6 @@ int QTextEngine::shapeTextWithHarfbuzzNG(const QScriptItem &si, #endif hb_buffer_set_segment_properties(buffer, &props); - hb_buffer_guess_segment_properties(buffer); uint buffer_flags = HB_BUFFER_FLAG_DEFAULT; // Symbol encoding used to encode various crap in the 32..255 character code range, |