Set preedit cursor when cursor equals to 0
Pick-to: 6.3 6.2 5.15 Change-Id: I832fbb22d973b36ac4ab51570fc53bc2e4c3ed58 Reviewed-by: Liang Qi <liang.qi@qt.io>
This commit is contained in:
parent
1616b042bb
commit
8b3de53ee6
@ -153,7 +153,7 @@ QInputMethodEvent *QWaylandInputMethodEventBuilder::buildPreedit(const QString &
|
||||
{
|
||||
QList<QInputMethodEvent::Attribute> attributes;
|
||||
|
||||
if (m_preeditCursor < 0) {
|
||||
if (m_preeditCursor <= 0) {
|
||||
attributes.append(QInputMethodEvent::Attribute(QInputMethodEvent::Cursor, 0, 0, QVariant()));
|
||||
} else if (m_preeditCursor > 0) {
|
||||
attributes.append(QInputMethodEvent::Attribute(QInputMethodEvent::Cursor, indexFromWayland(text, m_preeditCursor), 1, QVariant()));
|
||||
|
Loading…
x
Reference in New Issue
Block a user