![]() ![]() |
A text object on a QCanvas. More...
#include <qcanvas.h>
Inherits QCanvasItem.
A QCanvasText has text, a font, color, and position.
Constructs a QCanvasText with the text " Constructs a QCanvasText with the text t, on canvas.
The text should not contain newlines.
Constructs a QCanvasText with the text t and font f, on canvas.
The text should not contain newlines.
Destruct the sprite.
Returns the bounding rectangle of the text.
Reimplemented from QCanvasItem.
Reimplemented for internal reasons; the API is not affected.
Reimplemented from QCanvasItem.
Returns the color of the text.
See also: setColor().
Draws the text.
Returns the font in which the text is drawn.
See also: setFont().
Reimplemented for internal reasons; the API is not affected.
Reimplemented from QCanvasItem.
Returns 3.
See also: QCanvasItem::rtti().
Sets the color of the text.
See also: color() and setFont().
Sets the font in which the text is drawn.
See also: font().
Sets the text to be displayed. The text may contain newlines.
See also: text(), setFont() and setColor().
Sets the alignment flags. These are a bitwise OR or some of the
flags available to QPainter::drawText() - see Qt::AlignmentFlags.
The DontClip and WordBreak flags are not supported.
Returns the text to be displayed.
See also: setText().
Returns the currently set alignment flags.
See also: setTextFlags() and Qt::AlignmentFlags.
Search the documentation, FAQ, qt-interest archive and more (uses
www.trolltech.com):
This file is part of the Qt toolkit,
copyright © 1995-2000
Trolltech, all rights reserved.QCanvasText::QCanvasText ( const QString & t, QCanvas * canvas )
QCanvasText::QCanvasText ( const QString & t, QFont f, QCanvas * canvas )
QCanvasText::~QCanvasText ()
[virtual]
QRect QCanvasText::boundingRect () const
[virtual]
bool QCanvasText::collidesWith ( const QCanvasItem * i ) const
[virtual]
QColor QCanvasText::color () const
void QCanvasText::draw ( QPainter & painter )
[virtual protected]
QFont QCanvasText::font () const
void QCanvasText::moveBy ( double dx, double dy )
[virtual]
int QCanvasText::rtti () const
[virtual]
void QCanvasText::setColor ( const QColor & c )
void QCanvasText::setFont ( const QFont & f )
void QCanvasText::setText ( const QString & t )
void QCanvasText::setTextFlags ( int f )
QString QCanvasText::text () const
int QCanvasText::textFlags () const
Copyright İ 2000 Trolltech Trademarks