aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/items/qquicktextedit_p.h
diff options
context:
space:
mode:
authorAndrew den Exter <andrew.den-exter@nokia.com>2012-02-23 14:11:48 +1000
committerQt by Nokia <qt-info@nokia.com>2012-02-24 01:46:49 +0100
commit5fee1e79cc1c18acf58f9171a73a7525154a65cd (patch)
treecd6012dd79fa723cab96f498ab98879c0c27d415 /src/quick/items/qquicktextedit_p.h
parent8efc0ba05023654b6640a6050a4952becca4d68f (diff)
Use floating point types for position offsets and cursorRectangle.
Rounding to align painting to pixel boundaries is no longer necessary are largely removed. Correct the few instances remaining in TextEdit and TextInput. Change-Id: Ic6ec57092d74ec43b23d85cd8868e0190acc3e09 Reviewed-by: Yann Bodson <yann.bodson@nokia.com>
Diffstat (limited to 'src/quick/items/qquicktextedit_p.h')
-rw-r--r--src/quick/items/qquicktextedit_p.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/quick/items/qquicktextedit_p.h b/src/quick/items/qquicktextedit_p.h
index 5f6317ab09..b3fd32af69 100644
--- a/src/quick/items/qquicktextedit_p.h
+++ b/src/quick/items/qquicktextedit_p.h
@@ -79,7 +79,7 @@ class Q_AUTOTEST_EXPORT QQuickTextEdit : public QQuickImplicitSizeItem
Q_PROPERTY(bool readOnly READ isReadOnly WRITE setReadOnly NOTIFY readOnlyChanged)
Q_PROPERTY(bool cursorVisible READ isCursorVisible WRITE setCursorVisible NOTIFY cursorVisibleChanged)
Q_PROPERTY(int cursorPosition READ cursorPosition WRITE setCursorPosition NOTIFY cursorPositionChanged)
- Q_PROPERTY(QRect cursorRectangle READ cursorRectangle NOTIFY cursorRectangleChanged)
+ Q_PROPERTY(QRectF cursorRectangle READ cursorRectangle NOTIFY cursorRectangleChanged)
Q_PROPERTY(QDeclarativeComponent* cursorDelegate READ cursorDelegate WRITE setCursorDelegate NOTIFY cursorDelegateChanged)
Q_PROPERTY(int selectionStart READ selectionStart NOTIFY selectionStartChanged)
Q_PROPERTY(int selectionEnd READ selectionEnd NOTIFY selectionEndChanged)
@@ -212,7 +212,7 @@ public:
void setTextInteractionFlags(Qt::TextInteractionFlags flags);
Qt::TextInteractionFlags textInteractionFlags() const;
- QRect cursorRectangle() const;
+ QRectF cursorRectangle() const;
QVariant inputMethodQuery(Qt::InputMethodQuery property) const;
@@ -224,7 +224,7 @@ public:
void resetBaseUrl();
Q_INVOKABLE QRectF positionToRectangle(int) const;
- Q_INVOKABLE int positionAt(int x, int y) const;
+ Q_INVOKABLE int positionAt(qreal x, qreal y) const;
Q_INVOKABLE void moveCursorSelection(int pos);
Q_INVOKABLE void moveCursorSelection(int pos, SelectionMode mode);