summaryrefslogtreecommitdiffstats
path: root/src/gui/text
diff options
context:
space:
mode:
authorPrasanth Ullattil <prasanth.ullattil@nokia.com>2009-11-24 13:55:11 (GMT)
committerPrasanth Ullattil <prasanth.ullattil@nokia.com>2009-11-24 14:07:18 (GMT)
commit995629aba904f730b773b5a811e74f63ea0ff517 (patch)
tree3ad2f7587a97af7100052404ea0a4d9739b3521f /src/gui/text
parent203a13e83a224d646df854678fe63a66506b09a6 (diff)
downloadQt-995629aba904f730b773b5a811e74f63ea0ff517.zip
Qt-995629aba904f730b773b5a811e74f63ea0ff517.tar.gz
Qt-995629aba904f730b773b5a811e74f63ea0ff517.tar.bz2
Incorrect background while composing Japanese text(e.g 'shi' + <space>).
This happens only when there is a single japanese character entered & the suggested text is same as the one already displayed. In this case, black background was not drawn correctly. Reviewed-by: Simon Hausmann Reviewed-by: axis
Diffstat (limited to 'src/gui/text')
-rw-r--r--src/gui/text/qtextcontrol.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/gui/text/qtextcontrol.cpp b/src/gui/text/qtextcontrol.cpp
index 90e876c..f96f66b 100644
--- a/src/gui/text/qtextcontrol.cpp
+++ b/src/gui/text/qtextcontrol.cpp
@@ -1849,8 +1849,8 @@ void QTextControlPrivate::inputMethodEvent(QInputMethodEvent *e)
|| e->preeditString() != cursor.block().layout()->preeditAreaText()
|| e->replacementLength() > 0;
+ cursor.beginEditBlock();
if (isGettingInput) {
- cursor.beginEditBlock();
cursor.removeSelectedText();
}
@@ -1898,9 +1898,7 @@ void QTextControlPrivate::inputMethodEvent(QInputMethodEvent *e)
}
}
layout->setAdditionalFormats(overrides);
-
- if (isGettingInput)
- cursor.endEditBlock();
+ cursor.endEditBlock();
}
QVariant QTextControl::inputMethodQuery(Qt::InputMethodQuery property) const