1QCanvasSpline(3qt)                                          QCanvasSpline(3qt)
2
3
4

NAME

6       QCanvasSpline - Multi-bezier splines on a QCanvas
7

SYNOPSIS

9       #include <qcanvas.h>
10
11       Inherits QCanvasPolygon.
12
13   Public Members
14       QCanvasSpline ( QCanvas * canvas )
15       ~QCanvasSpline ()
16       void setControlPoints ( QPointArray ctrl, bool close = TRUE )
17       QPointArray controlPoints () const
18       bool closed () const
19       virtual int rtti () const
20

DESCRIPTION

22       The QCanvasSpline class provides multi-bezier splines on a QCanvas.
23
24       A QCanvasSpline is a sequence of 4-point bezier curves joined together
25       to make a curved shape.
26
27       You set the control points of the spline with setControlPoints().
28
29       If the bezier is closed(), then the first control point will be re-used
30       as the last control point. Therefore, a closed bezier must have a
31       multiple of 3 control points and an open bezier must have one extra
32       point.
33
34       The beziers are not necessarily joined "smoothly". To ensure this, set
35       control points appropriately (general reference texts about beziers
36       will explain this in detail).
37
38       Like any other canvas item splines can be moved with
39       QCanvasItem::move() and QCanvasItem::moveBy(), or by setting
40       coordinates with QCanvasItem::setX(), QCanvasItem::setY() and
41       QCanvasItem::setZ().
42
43       See also Graphics Classes and Image Processing Classes.
44

MEMBER FUNCTION DOCUMENTATION

QCanvasSpline::QCanvasSpline ( QCanvas * canvas )

47       Create a spline with no control points on the canvas canvas.
48
49       See also setControlPoints().
50

QCanvasSpline::~QCanvasSpline ()

52       Destroy the spline.
53

bool QCanvasSpline::closed () const

55       Returns TRUE if the control points are a closed set; otherwise returns
56       FALSE.
57

QPointArray QCanvasSpline::controlPoints () const

59       Returns the current set of control points.
60
61       See also setControlPoints() and closed().
62

int QCanvasSpline::rtti () const [virtual]

64       Returns 8 (QCanvasItem::Rtti_Spline).
65
66       See also QCanvasItem::rtti().
67
68       Reimplemented from QCanvasPolygon.
69

void QCanvasSpline::setControlPoints ( QPointArray ctrl, bool close = TRUE )

71       Set the spline control points to ctrl.
72
73       If close is TRUE, then the first point in ctrl will be re-used as the
74       last point, and the number of control points must be a multiple of 3.
75       If close is FALSE, one additional control point is required, and the
76       number of control points must be one of (4, 7, 10, 13, ...).
77
78       If the number of control points doesn't meet the above conditions, the
79       number of points will be truncated to the largest number of points that
80       do meet the requirement.
81
82       Example: canvas/canvas.cpp.
83
84

SEE ALSO

86       http://doc.trolltech.com/qcanvasspline.html
87       http://www.trolltech.com/faq/tech.html
88
90       Copyright 1992-2007 Trolltech ASA, http://www.trolltech.com.  See the
91       license file included in the distribution for a complete license
92       statement.
93

AUTHOR

95       Generated automatically from the source code.
96

BUGS

98       If you find a bug in Qt, please report it as described in
99       http://doc.trolltech.com/bughowto.html.  Good bug reports help us to
100       help you. Thank you.
101
102       The definitive Qt documentation is provided in HTML format; it is
103       located at $QTDIR/doc/html and can be read using Qt Assistant or with a
104       web browser. This man page is provided as a convenience for those users
105       who prefer man pages, although this format is not officially supported
106       by Trolltech.
107
108       If you find errors in this manual page, please report them to qt-
109       bugs@trolltech.com.  Please include the name of the manual page
110       (qcanvasspline.3qt) and the Qt version (3.3.8).
111
112
113
114Trolltech AS                    2 February 2007             QCanvasSpline(3qt)
Impressum