keyevents test: Force left to right when outputting key combinations

Otherwise characters in right to left languages like Hebrew might
mess up the output.

Change-Id: I8753e7e672159ed515dc6152c3629adf91cfd4a9
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
This commit is contained in:
Tor Arne Vestbø 2023-10-03 14:42:14 +02:00
parent c74cfae7a3
commit 5fce4ff2c2

View File

@ -106,7 +106,8 @@ public:
QStringList keyCombinations;
for (auto combination : event.possibleKeyCombinations)
keyCombinations << QKeySequence(combination).toString(QKeySequence::NativeText);
return keyCombinations.join(" ");
constexpr auto leftToRightOverride = QChar(0x202d);
return leftToRightOverride + keyCombinations.join(" ");
}
default: {
QStringList matches;