summaryrefslogtreecommitdiffstats
path: root/src/gui/text/qtextlayout.cpp
diff options
context:
space:
mode:
authorJiang Jiang <jiang.jiang@nokia.com>2011-05-11 12:13:01 +0200
committerJiang Jiang <jiang.jiang@nokia.com>2011-05-11 14:32:02 +0200
commit5eba82b752e85a5d6cb3a893214ed2646d75f362 (patch)
tree68470935e37155b5f1cef258043de8d0ee08e371 /src/gui/text/qtextlayout.cpp
parent360c5f2c39a39c2a8296f21e6f5f577367610853 (diff)
Move QTextCursor::MoveStyle to Qt namespace
We cannot use QTextCursor::MoveStyle enums in QTextLine because QTextCursor is not a QObject, while referring to that enum in Q_PROPERTY requires it to be. That's why we need to move the enums in Qt namespace. Reviewed-by: David Boddie
Diffstat (limited to 'src/gui/text/qtextlayout.cpp')
-rw-r--r--src/gui/text/qtextlayout.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/gui/text/qtextlayout.cpp b/src/gui/text/qtextlayout.cpp
index 1280b4650b..07aeb72a49 100644
--- a/src/gui/text/qtextlayout.cpp
+++ b/src/gui/text/qtextlayout.cpp
@@ -579,27 +579,27 @@ bool QTextLayout::cacheEnabled() const
}
/*!
- Set the visual cursor movement style. If the QTextLayout is backed by
+ Set the cursor movement style. If the QTextLayout is backed by
a document, you can ignore this and use the option in QTextDocument,
this option is for widgets like QLineEdit or custom widgets without
- a QTextDocument. Default value is QTextCursor::Logical.
+ a QTextDocument. Default value is Qt::LogicalMoveStyle.
\sa setCursorMoveStyle()
*/
-void QTextLayout::setCursorMoveStyle(QTextCursor::MoveStyle style)
+void QTextLayout::setCursorMoveStyle(Qt::CursorMoveStyle style)
{
- d->visualMovement = style == QTextCursor::Visual ? true : false;
+ d->visualMovement = style == Qt::VisualMoveStyle ? true : false;
}
/*!
The cursor movement style of this QTextLayout. The default is
- QTextCursor::Logical.
+ Qt::LogicalMoveStyle.
\sa setCursorMoveStyle()
*/
-QTextCursor::MoveStyle QTextLayout::cursorMoveStyle() const
+Qt::CursorMoveStyle QTextLayout::cursorMoveStyle() const
{
- return d->visualMovement ? QTextCursor::Visual : QTextCursor::Logical;
+ return d->visualMovement ? Qt::VisualMoveStyle : Qt::LogicalMoveStyle;
}
/*!