diff --git a/src/gui/text/qtextengine.cpp b/src/gui/text/qtextengine.cpp index a7e4748c88..41ea56a23a 100644 --- a/src/gui/text/qtextengine.cpp +++ b/src/gui/text/qtextengine.cpp @@ -323,7 +323,7 @@ static QChar::Direction skipBoundryNeutrals(QScriptAnalysis *analysis, const ushort *unicode, int length, int &sor, int &eor, QBidiControl &control) { - QChar::Direction dir; + QChar::Direction dir = control.basicDirection(); int level = sor > 0 ? analysis[sor - 1].bidiLevel : control.level; while (sor < length) { dir = QChar::direction(unicode[sor]);