summaryrefslogtreecommitdiffstats
path: root/src/declarative/graphicsitems/qdeclarativetextedit_p_p.h
diff options
context:
space:
mode:
authorJoona Petrell <joona.t.petrell@nokia.com>2011-03-01 02:51:27 (GMT)
committerJoona Petrell <joona.t.petrell@nokia.com>2011-03-01 07:40:23 (GMT)
commit88253db8a7d7910e1393b1948fb3747117538c92 (patch)
tree038cb2a758150312a6dfd1d4e6cd5f4bf548e215 /src/declarative/graphicsitems/qdeclarativetextedit_p_p.h
parentd5c72c6fb75357061c5f9e0d0d2efdaff9140741 (diff)
downloadQt-88253db8a7d7910e1393b1948fb3747117538c92.zip
Qt-88253db8a7d7910e1393b1948fb3747117538c92.tar.gz
Qt-88253db8a7d7910e1393b1948fb3747117538c92.tar.bz2
Make sure horizontal QML editor text aligment always returns the actual alignment
Also, implicit empty text alignment now follows the Application's default layout direction traditionally set by the locale. Task-number: QTBUG-15880 Reviewed-by: Martin Jones Change-Id: I88340513d489290bafd393072786a19731097b77
Diffstat (limited to 'src/declarative/graphicsitems/qdeclarativetextedit_p_p.h')
-rw-r--r--src/declarative/graphicsitems/qdeclarativetextedit_p_p.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/declarative/graphicsitems/qdeclarativetextedit_p_p.h b/src/declarative/graphicsitems/qdeclarativetextedit_p_p.h
index 111cc02..f4a6c0e 100644
--- a/src/declarative/graphicsitems/qdeclarativetextedit_p_p.h
+++ b/src/declarative/graphicsitems/qdeclarativetextedit_p_p.h
@@ -71,8 +71,8 @@ public:
: color("black"), hAlign(QDeclarativeTextEdit::AlignLeft), vAlign(QDeclarativeTextEdit::AlignTop),
imgDirty(true), dirty(false), richText(false), cursorVisible(false), focusOnPress(true),
showInputPanelOnFocus(true), clickCausedFocus(false), persistentSelection(true), requireImplicitWidth(false),
- textMargin(0.0), lastSelectionStart(0), lastSelectionEnd(0), cursorComponent(0), cursor(0),
- format(QDeclarativeTextEdit::AutoText), document(0), wrapMode(QDeclarativeTextEdit::NoWrap),
+ hAlignImplicit(true), rightToLeftText(false), textMargin(0.0), lastSelectionStart(0), lastSelectionEnd(0),
+ cursorComponent(0), cursor(0), format(QDeclarativeTextEdit::AutoText), document(0), wrapMode(QDeclarativeTextEdit::NoWrap),
mouseSelectionMode(QDeclarativeTextEdit::SelectCharacters), selectByMouse(false), canPaste(false),
yoff(0)
{
@@ -88,6 +88,7 @@ public:
void updateDefaultTextOption();
void relayoutDocument();
void updateSelection();
+ void determineHorizontalAlignment();
qreal implicitWidth() const;
void focusChanged(bool);
@@ -112,6 +113,8 @@ public:
bool clickCausedFocus : 1;
bool persistentSelection : 1;
bool requireImplicitWidth:1;
+ bool hAlignImplicit:1;
+ bool rightToLeftText:1;
qreal textMargin;
int lastSelectionStart;
int lastSelectionEnd;