135 PaintUsingTextFont = 0x01,
138 PaintUsingTextColor = 0x02,
141 PaintBackground = 0x04
144 Q_DECLARE_FLAGS(PaintAttributes, PaintAttribute)
162 Q_DECLARE_FLAGS(LayoutAttributes, LayoutAttribute)
167 QwtText(
const QString&, TextFormat textFormat = AutoText);
182 bool operator==(const
QwtText&) const;
184 bool operator!=(const
QwtText&) const;
187 void setText(const QString&,
QwtText::TextFormat textFormat = AutoText);
189 QString text() const;
194 bool isEmpty() const;
197 void setFont(const QFont&);
202 QFont usedFont(const QFont&) const;
205 TextFormat format() const;
208 void setRenderFlags(
int);
210 int renderFlags() const;
213 void setColor(const QColor&);
215 QColor color() const;
218 QColor usedColor(const QColor&) const;
221 void setBorderRadius(
double);
223 double borderRadius() const;
226 void setBorderPen(const QPen&);
228 QPen borderPen() const;
231 void setBackgroundBrush(const QBrush&);
233 QBrush backgroundBrush() const;
236 void setPaintAttribute(PaintAttribute,
bool on = true);
238 bool testPaintAttribute(PaintAttribute) const;
241 void setLayoutAttribute(LayoutAttribute,
bool on = true);
243 bool testLayoutAttribute(LayoutAttribute) const;
246 double heightForWidth(
double width) const;
248 double heightForWidth(
double width, const QFont&) const;
251 QSizeF textSize() const;
253 QSizeF textSize(const QFont&) const;
256 void draw(QPainter* painter, const QRectF& rect) const;
270 LayoutCache* m_layoutCache;
Abstract base class for rendering text strings
Definition qwt_text_engine.h:46
A class representing a text
Definition qwt_text.h:70
LayoutAttribute
Layout Attributes The layout attributes affects some aspects of the layout of the text.
Definition qwt_text.h:152
@ RichText
Use the Scribe framework (Qt Rich Text) to render the text.
Definition qwt_text.h:95
@ PlainText
Draw the text as it is, using a QwtPlainTextEngine.
Definition qwt_text.h:92
@ MathMLText
Definition qwt_text.h:110
@ TeXText
Definition qwt_text.h:116
PaintAttribute
Paint Attributes
Definition qwt_text.h:133