diff options
author | Alan Alpert <alan.alpert@nokia.com> | 2009-11-12 05:34:21 (GMT) |
---|---|---|
committer | Alan Alpert <alan.alpert@nokia.com> | 2009-11-12 05:34:21 (GMT) |
commit | 05c1b075f757afcc87748ac6758277eb5c0d8e17 (patch) | |
tree | 9f3159998e643ccd96313c94fb5eac2782aa3aab /src/gui/widgets/qlineedit.cpp | |
parent | 87845845cd5b44bc4ad391ad5ae8499f3850acb3 (diff) | |
parent | db3ae6188c8f88f25b4f8e2645e76a7c6fffef18 (diff) | |
download | Qt-05c1b075f757afcc87748ac6758277eb5c0d8e17.zip Qt-05c1b075f757afcc87748ac6758277eb5c0d8e17.tar.gz Qt-05c1b075f757afcc87748ac6758277eb5c0d8e17.tar.bz2 |
Merge branch 'kinetic-declarativeui' of git@scm.dev.nokia.troll.no:qt/kinetic into kinetic-declarativeui
Diffstat (limited to 'src/gui/widgets/qlineedit.cpp')
-rw-r--r-- | src/gui/widgets/qlineedit.cpp | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/src/gui/widgets/qlineedit.cpp b/src/gui/widgets/qlineedit.cpp index e4252b5..f5dbe1c 100644 --- a/src/gui/widgets/qlineedit.cpp +++ b/src/gui/widgets/qlineedit.cpp @@ -1102,6 +1102,17 @@ void QLineEdit::setTextMargins(int left, int top, int right, int bottom) } /*! + \since 4.6 + Sets the \a margins around the text inside the frame. + + See also textMargins(). +*/ +void QLineEdit::setTextMargins(const QMargins &margins) +{ + setTextMargins(margins.left(), margins.top(), margins.right(), margins.bottom()); +} + +/*! Returns the widget's text margins for \a left, \a top, \a right, and \a bottom. \since 4.5 @@ -1121,6 +1132,18 @@ void QLineEdit::getTextMargins(int *left, int *top, int *right, int *bottom) con } /*! + \since 4.6 + Returns the widget's text margins. + + \sa setTextMargins() +*/ +QMargins QLineEdit::textMargins() const +{ + Q_D(const QLineEdit); + return QMargins(d->leftTextMargin, d->topTextMargin, d->rightTextMargin, d->bottomTextMargin); +} + +/*! \property QLineEdit::inputMask \brief The validation input mask |