1 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
---|
2 | <!-- /home/espenr/tmp/qt-3.3.8-espenr-2499/qt-x11-free-3.3.8/src/canvas/qcanvas.cpp:4389 -->
|
---|
3 | <html>
|
---|
4 | <head>
|
---|
5 | <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
---|
6 | <title>QCanvasLine Class</title>
|
---|
7 | <style type="text/css"><!--
|
---|
8 | fn { margin-left: 1cm; text-indent: -1cm; }
|
---|
9 | a:link { color: #004faf; text-decoration: none }
|
---|
10 | a:visited { color: #672967; text-decoration: none }
|
---|
11 | body { background: #ffffff; color: black; }
|
---|
12 | --></style>
|
---|
13 | </head>
|
---|
14 | <body>
|
---|
15 |
|
---|
16 | <table border="0" cellpadding="0" cellspacing="0" width="100%">
|
---|
17 | <tr bgcolor="#E5E5E5">
|
---|
18 | <td valign=center>
|
---|
19 | <a href="index.html">
|
---|
20 | <font color="#004faf">Home</font></a>
|
---|
21 | | <a href="classes.html">
|
---|
22 | <font color="#004faf">All Classes</font></a>
|
---|
23 | | <a href="mainclasses.html">
|
---|
24 | <font color="#004faf">Main Classes</font></a>
|
---|
25 | | <a href="annotated.html">
|
---|
26 | <font color="#004faf">Annotated</font></a>
|
---|
27 | | <a href="groups.html">
|
---|
28 | <font color="#004faf">Grouped Classes</font></a>
|
---|
29 | | <a href="functions.html">
|
---|
30 | <font color="#004faf">Functions</font></a>
|
---|
31 | </td>
|
---|
32 | <td align="right" valign="center"><img src="logo32.png" align="right" width="64" height="32" border="0"></td></tr></table><h1 align=center>QCanvasLine Class Reference<br><small>[<a href="canvas.html">canvas module</a>]</small></h1>
|
---|
33 |
|
---|
34 | <p>The QCanvasLine class provides a line on a QCanvas.
|
---|
35 | <a href="#details">More...</a>
|
---|
36 | <p><tt>#include <<a href="qcanvas-h.html">qcanvas.h</a>></tt>
|
---|
37 | <p>Inherits <a href="qcanvaspolygonalitem.html">QCanvasPolygonalItem</a>.
|
---|
38 | <p><a href="qcanvasline-members.html">List of all member functions.</a>
|
---|
39 | <h2>Public Members</h2>
|
---|
40 | <ul>
|
---|
41 | <li class=fn><a href="#QCanvasLine"><b>QCanvasLine</b></a> ( QCanvas * canvas )</li>
|
---|
42 | <li class=fn><a href="#~QCanvasLine"><b>~QCanvasLine</b></a> ()</li>
|
---|
43 | <li class=fn>void <a href="#setPoints"><b>setPoints</b></a> ( int xa, int ya, int xb, int yb )</li>
|
---|
44 | <li class=fn>QPoint <a href="#startPoint"><b>startPoint</b></a> () const</li>
|
---|
45 | <li class=fn>QPoint <a href="#endPoint"><b>endPoint</b></a> () const</li>
|
---|
46 | <li class=fn>virtual int <a href="#rtti"><b>rtti</b></a> () const</li>
|
---|
47 | </ul>
|
---|
48 | <hr><a name="details"></a><h2>Detailed Description</h2>
|
---|
49 |
|
---|
50 |
|
---|
51 | The QCanvasLine class provides a line on a <a href="qcanvas.html">QCanvas</a>.
|
---|
52 |
|
---|
53 | <p>
|
---|
54 |
|
---|
55 |
|
---|
56 | <p> The line inherits functionality from <a href="qcanvaspolygonalitem.html">QCanvasPolygonalItem</a>, for
|
---|
57 | example the <a href="qcanvaspolygonalitem.html#setPen">setPen</a>() function. The start and end points of the
|
---|
58 | line are set with <a href="#setPoints">setPoints</a>().
|
---|
59 | <p> Like any other canvas item lines can be moved with
|
---|
60 | <a href="qcanvasitem.html#move">QCanvasItem::move</a>() and <a href="qcanvasitem.html#moveBy">QCanvasItem::moveBy</a>(), or by setting
|
---|
61 | coordinates with <a href="qcanvasitem.html#setX">QCanvasItem::setX</a>(), <a href="qcanvasitem.html#setY">QCanvasItem::setY</a>() and
|
---|
62 | <a href="qcanvasitem.html#setZ">QCanvasItem::setZ</a>().
|
---|
63 | <p>See also <a href="graphics.html">Graphics Classes</a> and <a href="images.html">Image Processing Classes</a>.
|
---|
64 |
|
---|
65 | <hr><h2>Member Function Documentation</h2>
|
---|
66 | <h3 class=fn><a name="QCanvasLine"></a>QCanvasLine::QCanvasLine ( <a href="qcanvas.html">QCanvas</a> * canvas )
|
---|
67 | </h3>
|
---|
68 | Constructs a line from (0,0) to (0,0) on <em>canvas</em>.
|
---|
69 | <p> <p>See also <a href="#setPoints">setPoints</a>().
|
---|
70 |
|
---|
71 | <h3 class=fn><a name="~QCanvasLine"></a>QCanvasLine::~QCanvasLine ()
|
---|
72 | </h3>
|
---|
73 | Destroys the line.
|
---|
74 |
|
---|
75 | <h3 class=fn><a href="qpoint.html">QPoint</a> <a name="endPoint"></a>QCanvasLine::endPoint () const
|
---|
76 | </h3>
|
---|
77 |
|
---|
78 | <p> Returns the end point of the line.
|
---|
79 | <p> <p>See also <a href="#setPoints">setPoints</a>() and <a href="#startPoint">startPoint</a>().
|
---|
80 |
|
---|
81 | <h3 class=fn>int <a name="rtti"></a>QCanvasLine::rtti () const<tt> [virtual]</tt>
|
---|
82 | </h3>
|
---|
83 | Returns 7 (QCanvasItem::Rtti_Line).
|
---|
84 | <p> <p>See also <a href="qcanvasitem.html#rtti">QCanvasItem::rtti</a>().
|
---|
85 |
|
---|
86 | <p>Reimplemented from <a href="qcanvaspolygonalitem.html#rtti">QCanvasPolygonalItem</a>.
|
---|
87 | <h3 class=fn>void <a name="setPoints"></a>QCanvasLine::setPoints ( int xa, int ya, int xb, int yb )
|
---|
88 | </h3>
|
---|
89 | Sets the line's start point to (<em>xa</em>, <em>ya</em>) and its end point to
|
---|
90 | (<em>xb</em>, <em>yb</em>).
|
---|
91 |
|
---|
92 | <p>Example: <a href="canvas-example.html#x2922">canvas/canvas.cpp</a>.
|
---|
93 | <h3 class=fn><a href="qpoint.html">QPoint</a> <a name="startPoint"></a>QCanvasLine::startPoint () const
|
---|
94 | </h3>
|
---|
95 |
|
---|
96 | <p> Returns the start point of the line.
|
---|
97 | <p> <p>See also <a href="#setPoints">setPoints</a>() and <a href="#endPoint">endPoint</a>().
|
---|
98 |
|
---|
99 | <!-- eof -->
|
---|
100 | <hr><p>
|
---|
101 | This file is part of the <a href="index.html">Qt toolkit</a>.
|
---|
102 | Copyright © 1995-2007
|
---|
103 | <a href="http://www.trolltech.com/">Trolltech</a>. All Rights Reserved.<p><address><hr><div align=center>
|
---|
104 | <table width=100% cellspacing=0 border=0><tr>
|
---|
105 | <td>Copyright © 2007
|
---|
106 | <a href="troll.html">Trolltech</a><td align=center><a href="trademarks.html">Trademarks</a>
|
---|
107 | <td align=right><div align=right>Qt 3.3.8</div>
|
---|
108 | </table></div></address></body>
|
---|
109 | </html>
|
---|