Warning, file /include/QtGui/qinputmethod.h was not indexed
or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).
0001
0002
0003
0004 #ifndef QINPUTMETHOD_H
0005 #define QINPUTMETHOD_H
0006
0007 #include <QtGui/qtguiglobal.h>
0008 #include <QtCore/qobject.h>
0009
0010 QT_BEGIN_NAMESPACE
0011
0012 class QInputMethodPrivate;
0013 class QWindow;
0014 class QRectF;
0015 class QTransform;
0016 class QInputMethodQueryEvent;
0017
0018 class Q_GUI_EXPORT QInputMethod : public QObject
0019 {
0020 Q_OBJECT
0021 Q_DECLARE_PRIVATE(QInputMethod)
0022 Q_PROPERTY(QRectF cursorRectangle READ cursorRectangle NOTIFY cursorRectangleChanged)
0023 Q_PROPERTY(QRectF anchorRectangle READ anchorRectangle NOTIFY anchorRectangleChanged)
0024 Q_PROPERTY(QRectF keyboardRectangle READ keyboardRectangle NOTIFY keyboardRectangleChanged)
0025 Q_PROPERTY(QRectF inputItemClipRectangle READ inputItemClipRectangle
0026 NOTIFY inputItemClipRectangleChanged)
0027 Q_PROPERTY(bool visible READ isVisible NOTIFY visibleChanged)
0028 Q_PROPERTY(bool animating READ isAnimating NOTIFY animatingChanged)
0029 Q_PROPERTY(QLocale locale READ locale NOTIFY localeChanged)
0030 Q_PROPERTY(Qt::LayoutDirection inputDirection READ inputDirection NOTIFY inputDirectionChanged)
0031
0032 public:
0033 QTransform inputItemTransform() const;
0034 void setInputItemTransform(const QTransform &transform);
0035
0036 QRectF inputItemRectangle() const;
0037 void setInputItemRectangle(const QRectF &rect);
0038
0039
0040 QRectF cursorRectangle() const;
0041 QRectF anchorRectangle() const;
0042
0043
0044 QRectF keyboardRectangle() const;
0045
0046 QRectF inputItemClipRectangle() const;
0047
0048 enum Action {
0049 Click,
0050 ContextMenu
0051 };
0052 Q_ENUM(Action)
0053
0054 bool isVisible() const;
0055 void setVisible(bool visible);
0056
0057 bool isAnimating() const;
0058
0059 QLocale locale() const;
0060 Qt::LayoutDirection inputDirection() const;
0061
0062 static QVariant queryFocusObject(Qt::InputMethodQuery query, const QVariant &argument);
0063
0064 public Q_SLOTS:
0065 void show();
0066 void hide();
0067
0068 void update(Qt::InputMethodQueries queries);
0069 void reset();
0070 void commit();
0071
0072 void invokeAction(Action a, int cursorPosition);
0073
0074 Q_SIGNALS:
0075 void cursorRectangleChanged();
0076 void anchorRectangleChanged();
0077 void keyboardRectangleChanged();
0078 void inputItemClipRectangleChanged();
0079 void visibleChanged();
0080 void animatingChanged();
0081 void localeChanged();
0082 void inputDirectionChanged(Qt::LayoutDirection newDirection);
0083
0084 private:
0085 friend class QGuiApplication;
0086 friend class QGuiApplicationPrivate;
0087 friend class QPlatformInputContext;
0088 QInputMethod();
0089 ~QInputMethod();
0090 };
0091
0092 QT_END_NAMESPACE
0093
0094 #endif