/****************************************************************************
**
** Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies).
-** All rights reserved.
-** Contact: Nokia Corporation (qt-info@nokia.com)
+** Contact: http://www.qt-project.org/
**
** This file is part of the QtDeclarative module of the Qt Toolkit.
**
**
**
**
+**
** $QT_END_LICENSE$
**
****************************************************************************/
Q_PROPERTY(bool selectByMouse READ selectByMouse WRITE setSelectByMouse NOTIFY selectByMouseChanged)
Q_PROPERTY(SelectionMode mouseSelectionMode READ mouseSelectionMode WRITE setMouseSelectionMode NOTIFY mouseSelectionModeChanged)
Q_PROPERTY(bool canPaste READ canPaste NOTIFY canPasteChanged)
+ Q_PROPERTY(bool canUndo READ canUndo NOTIFY canUndoChanged)
+ Q_PROPERTY(bool canRedo READ canRedo NOTIFY canRedoChanged)
Q_PROPERTY(bool inputMethodComposing READ isInputMethodComposing NOTIFY inputMethodComposingChanged)
public:
QRectF boundingRect() const;
bool canPaste() const;
+ bool canUndo() const;
+ bool canRedo() const;
+
bool isInputMethodComposing() const;
Qt::InputMethodHints imHints() const;
void selectByMouseChanged(bool selectByMouse);
void mouseSelectionModeChanged(SelectionMode mode);
void canPasteChanged();
+ void canUndoChanged();
+ void canRedoChanged();
void inputMethodComposingChanged();
void effectiveHorizontalAlignmentChanged();
void copy();
void paste();
#endif
+ void undo();
+ void redo();
void insert(int position, const QString &text);
void remove(int start, int end);
void createCursor();
void updateCursorRectangle();
void q_canPasteChanged();
+ void q_updateAlignment();
+ void triggerPreprocess();
private:
Q_DECLARE_PRIVATE(QQuickTextInput)
};
+#ifndef QT_NO_VALIDATOR
+class Q_AUTOTEST_EXPORT QQuickIntValidator : public QIntValidator
+{
+ Q_OBJECT
+ Q_PROPERTY(QString locale READ localeName WRITE setLocaleName RESET resetLocaleName NOTIFY localeNameChanged)
+public:
+ QQuickIntValidator(QObject *parent = 0);
+
+ QString localeName() const;
+ void setLocaleName(const QString &name);
+ void resetLocaleName();
+
+Q_SIGNALS:
+ void localeNameChanged();
+};
+
+class Q_AUTOTEST_EXPORT QQuickDoubleValidator : public QDoubleValidator
+{
+ Q_OBJECT
+ Q_PROPERTY(QString locale READ localeName WRITE setLocaleName RESET resetLocaleName NOTIFY localeNameChanged)
+public:
+ QQuickDoubleValidator(QObject *parent = 0);
+
+ QString localeName() const;
+ void setLocaleName(const QString &name);
+ void resetLocaleName();
+
+Q_SIGNALS:
+ void localeNameChanged();
+};
+#endif
+
QT_END_NAMESPACE
QML_DECLARE_TYPE(QQuickTextInput)
#ifndef QT_NO_VALIDATOR
QML_DECLARE_TYPE(QValidator)
-QML_DECLARE_TYPE(QIntValidator)
-QML_DECLARE_TYPE(QDoubleValidator)
+QML_DECLARE_TYPE(QQuickIntValidator)
+QML_DECLARE_TYPE(QQuickDoubleValidator)
QML_DECLARE_TYPE(QRegExpValidator)
#endif