summaryrefslogtreecommitdiffstats
path: root/src/gui/text/qstatictext.h
diff options
context:
space:
mode:
authorEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>2010-02-15 15:13:44 +0100
committerEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>2010-02-15 15:13:44 +0100
commit3a205ce73d4f87ad499b09cc7a7eb43c61c26cf9 (patch)
treee067aaf496be3791ecb36407fb5db7a13d93fd73 /src/gui/text/qstatictext.h
parent9f387357a7e171636c97a7ef13afca60c01a9e3b (diff)
Separate out textFormat property from setText() function and remove
isEmpty() function in QStaticText To make the return value of text() more intuitively clearer, and to make the API more readable, I've separated out the text format into a separate property. The isEmpty() function seemed out-of-place in the API, as suggested by reviews, so it has been removed.
Diffstat (limited to 'src/gui/text/qstatictext.h')
-rw-r--r--src/gui/text/qstatictext.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/gui/text/qstatictext.h b/src/gui/text/qstatictext.h
index 7498ad4218..8eeb068605 100644
--- a/src/gui/text/qstatictext.h
+++ b/src/gui/text/qstatictext.h
@@ -65,9 +65,12 @@ public:
QStaticText(const QStaticText &other);
~QStaticText();
- void setText(const QString &text, Qt::TextFormat textFormat = Qt::AutoText);
+ void setText(const QString &text);
QString text() const;
+ void setTextFormat(Qt::TextFormat textFormat);
+ Qt::TextFormat textFormat() const;
+
void setMaximumSize(const QSizeF &maximumSize);
QSizeF maximumSize() const;
@@ -82,8 +85,6 @@ public:
bool operator==(const QStaticText &) const;
bool operator!=(const QStaticText &) const;
- bool isEmpty() const;
-
private:
void detach();