📄 qcanvastext.3qt
字号:
.TH QCanvasText 3qt "10 November 2000" "Trolltech AS" \" -*- nroff -*-.\" Copyright 1992-2000 Trolltech AS. All rights reserved. See the.\" license file included in the distribution for a complete license.\" statement..\".ad l.nh.SH NAMEQCanvasText \- A text object on a QCanvas<h1 align=center>QCanvasText Class Reference.br<small>[ canvas module ]</small></h1>.br.PP\fC#include <qcanvas.h>\fR.PPInherits QCanvasItem..PP.SS "Public Members".in +1c.ti -1c.BI "\fBQCanvasText\fR ( QCanvas * canvas ) ".br.ti -1c.BI "\fBQCanvasText\fR ( const QString &, QCanvas * canvas ) ".br.ti -1c.BI "\fBQCanvasText\fR ( const QString &, QFont, QCanvas * canvas ) ".br.ti -1c.BI "virtual \fB~QCanvasText\fR () ".br.ti -1c.BI "void \fBsetText\fR ( const QString & ) ".br.ti -1c.BI "void \fBsetFont\fR ( const QFont & ) ".br.ti -1c.BI "void \fBsetColor\fR ( const QColor & ) ".br.ti -1c.BI "QString \fBtext\fR () const".br.ti -1c.BI "QFont \fBfont\fR () const".br.ti -1c.BI "QColor \fBcolor\fR () const".br.ti -1c.BI "int \fBtextFlags\fR () const".br.ti -1c.BI "void \fBsetTextFlags\fR ( int ) ".br.ti -1c.BI "virtual QRect \fBboundingRect\fR () const".br.ti -1c.BI "virtual int \fBrtti\fR () const".br.in -1c.SS "Protected Members".in +1c.ti -1c.BI "virtual void \fBdraw\fR ( QPainter & ) ".br.in -1c.SH DESCRIPTIONA text object on a QCanvas..PPA QCanvasText has text, a font, color, and position..SH MEMBER FUNCTION DOCUMENTATION.SH "QCanvasText::QCanvasText ( QCanvas * canvas )"Constructs a QCanvasText with the text "<text>", on \fIcanvas.\fR.SH "QCanvasText::QCanvasText ( const QString & t, QCanvas * canvas )"Constructs a QCanvasText with the text \fIt,\fR on \fIcanvas.\fR.PPThe text should not contain newlines..SH "QCanvasText::QCanvasText ( const QString & t, QFont f, QCanvas * canvas )"Constructs a QCanvasText with the text \fIt\fR and font \fIf,\fR on \fIcanvas.\fR.PPThe text should not contain newlines..SH "QCanvasText::~QCanvasText () \fC[virtual]\fR"Destruct the sprite..SH "QRect QCanvasText::boundingRect () const \fC[virtual]\fR"Returns the bounding rectangle of the text..PPReimplemented from QCanvasItem..SH "bool QCanvasText::collidesWith ( const QCanvasItem * i ) const \fC[virtual]\fR"Reimplemented for internal reasons; the API is not affected..PPReimplemented from QCanvasItem..SH "QColor QCanvasText::color () const"Returns the color of the text..PPSee also setColor()..SH "void QCanvasText::draw ( QPainter & painter ) \fC[virtual protected]\fR"Draws the text..SH "QFont QCanvasText::font () const"Returns the font in which the text is drawn..PPSee also setFont()..SH "void QCanvasText::moveBy ( double dx, double dy ) \fC[virtual]\fR"Reimplemented for internal reasons; the API is not affected..PPReimplemented from QCanvasItem..SH "int QCanvasText::rtti () const \fC[virtual]\fR"Returns 3..PPSee also QCanvasItem::rtti()..SH "void QCanvasText::setColor ( const QColor & c )"Sets the color of the text..PPSee also color() and setFont()..SH "void QCanvasText::setFont ( const QFont & f )"Sets the font in which the text is drawn..PPSee also font()..SH "void QCanvasText::setText ( const QString & t )"Sets the text to be displayed. The text may contain newlines..PPSee also text(), setFont() and setColor()..SH "void QCanvasText::setTextFlags ( int f )"Sets the alignment flags. These are a bitwise OR or \fIsome\fR of the flags available to QPainter::drawText() - see Qt::AlignmentFlags..PPThe DontClip and WordBreak flags are not supported..SH "QString QCanvasText::text () const"Returns the text to be displayed..PPSee also setText()..SH "int QCanvasText::textFlags () const"Returns the currently set alignment flags..PPSee also setTextFlags() and Qt::AlignmentFlags..SH "SEE ALSO".BR http://doc.trolltech.com/qcanvastext.html.SH COPYRIGHTCopyright 1992-2000 Trolltech AS, http://www.trolltech.com/. See thelicense file included in the distribution for a complete licensestatement..SH AUTHORGenerated automatically from the source code.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -