summaryrefslogtreecommitdiffstats
path: root/src/gui/doc/snippets/textdocument-selections/mainwindow.cpp
diff options
context:
space:
mode:
authorTor Arne Vestbø <tor.arne.vestbo@qt.io>2022-12-02 12:37:48 +0100
committerTor Arne Vestbø <tor.arne.vestbo@qt.io>2023-01-10 20:09:34 +0100
commit419cf9245a321797393e30fcbb12dff6149295e8 (patch)
tree19b9f3e059f4d1f165808b0cfb65bfad15a680da /src/gui/doc/snippets/textdocument-selections/mainwindow.cpp
parent2c78c5d4569d89c204857ab007f9e260b219d624 (diff)
Clarify that QKeyEvent::text() may return non-printable characters
This is the case for keys such as Qt::Key_Delete ("\u007F"), and Qt::ControlModifier + Qt::Key_C ("\u0003") on Windows and XCB, as well as potentially any key event on macOS when IM is not enabled, as of 705665957baf16f9ec4d256dd4d2fad98788314b. We can not filter QKeyEvent text() based on QChar::isPrint() or similar, as there might e.g. be valid printable text in the private use area, depending on the script and available fonts. See QInputControl::isAcceptableInput() for some of this complexity. Task-number: QTBUG-106393 Change-Id: I84d7ed86f57c1b605ac512d0f7ab66f6a11ed7bb Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
Diffstat (limited to 'src/gui/doc/snippets/textdocument-selections/mainwindow.cpp')
0 files changed, 0 insertions, 0 deletions