Deprecate QInputMethodEvent::setTentativeCommitString()
authorPekka Vuorela <pekka.ta.vuorela@nokia.com>
Tue, 28 Feb 2012 12:23:36 +0000 (14:23 +0200)
committerQt by Nokia <qt-info@nokia.com>
Fri, 23 Mar 2012 01:44:08 +0000 (02:44 +0100)
Free form tentative commit proved to require too much fiddling on
rendered text vs. logical content. Needs simpler mechanism.

Change-Id: Ia4e341abf342d25675fd1129efb11094dde410b2
Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com>
src/gui/kernel/qevent.cpp
src/gui/kernel/qevent.h

index e8ed5c0..436ed56 100644 (file)
@@ -1698,6 +1698,7 @@ void QInputMethodEvent::setCommitString(const QString &commitString, int replace
 
     The tentative commit string is what the preedit string is expected to be committed as.
     The string can be used within the editor to trigger code that reacts on text changes such as validators.
+    \deprecated
 */
 void QInputMethodEvent::setTentativeCommitString(const QString &tentativeCommitString)
 {
@@ -1758,6 +1759,7 @@ void QInputMethodEvent::setTentativeCommitString(const QString &tentativeCommitS
 
     Returns the text as which preedit string is expected to be committed as.
     The string can be used within the editor to trigger code that reacts on text changes such as validators.
+    \deprecated
 
     \sa setTentativeCommitString()
 */
index d70f6be..a042922 100644 (file)
@@ -444,7 +444,7 @@ public:
     QInputMethodEvent();
     QInputMethodEvent(const QString &preeditText, const QList<Attribute> &attributes);
     void setCommitString(const QString &commitString, int replaceFrom = 0, int replaceLength = 0);
-    void setTentativeCommitString(const QString &tentativeCommitString);
+    QT_DEPRECATED void setTentativeCommitString(const QString &tentativeCommitString);
 
     inline const QList<Attribute> &attributes() const { return attrs; }
     inline const QString &preeditString() const { return preedit; }
@@ -452,7 +452,7 @@ public:
     inline const QString &commitString() const { return commit; }
     inline int replacementStart() const { return replace_from; }
     inline int replacementLength() const { return replace_length; }
-    inline const QString &tentativeCommitString() const { return tentativeCommit; }
+    QT_DEPRECATED inline const QString &tentativeCommitString() const { return tentativeCommit; }
 
     QInputMethodEvent(const QInputMethodEvent &other);