1
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
4
<META HTTP-EQUIV="CONTENT-TYPE" CONTENT="text/html; charset=ibm437">
5
<TITLE>Magick::Drawable Class</TITLE>
6
<META NAME="GENERATOR" CONTENT="StarOffice 6.0 (Solaris Sparc)">
7
<META NAME="AUTHOR" CONTENT="Bob Friesenhahn">
8
<META NAME="CREATED" CONTENT="20020805;15043598">
9
<META NAME="CHANGEDBY" CONTENT="Bob Friesenhahn">
10
<META NAME="CHANGED" CONTENT="20021124;11445600">
11
<META NAME="DESCRIPTION" CONTENT="Documentation for Magick::Drawable class">
14
TD P { color: #000000 }
15
TD P.western { font-size: 11pt }
20
TH P { color: #000000 }
21
TH P.western { font-size: 11pt }
22
A:link { color: #0000ee }
23
A:visited { color: #551a8b }
27
<BODY LANG="en-US" TEXT="#000000" LINK="#0000ee" VLINK="#551a8b" BGCOLOR="#ffffff">
28
<H1 ALIGN=CENTER>Magick::Drawable</H1>
29
<P>Drawable provides a convenient interface for preparing vector,
30
image, or text arguments for the Image::draw() method. Each instance
31
of a Drawable sub-class represents a single drawable object. Drawable
32
objects may be drawn "one-by-one" via multiple invocations
33
of the Image <A HREF="Image.html#draw">draw</A>() method, or may be
34
drawn "all-at-once" by passing a list of Drawable objects
35
to the Image <A HREF="Image.html#draw">draw</A>() method. The
36
one-by-one approach is convenient for simple drawings, while the
37
list-based approach is appropriate for drawings which require more
40
<P>The following is an example using the Drawable subclasses with a
41
one-by-one approach to draw the following figure:
43
<P><FONT COLOR="#000000"><FONT COLOR="#000000"><IMG SRC="Drawable_example_1.png" NAME="Graphic1" ALIGN=BOTTOM WIDTH=300 HEIGHT=200 BORDER=3></FONT></FONT>
45
<P><TT><FONT COLOR="#000066">#include <string></FONT></TT>
46
<BR><TT><FONT COLOR="#000066">#include <iostream></FONT></TT>
47
<BR><TT><FONT COLOR="#000066">#include <Magick++.h></FONT></TT>
49
<P><TT><FONT COLOR="#000066">using namespace std;</FONT></TT> <BR><TT><FONT COLOR="#000066">using
50
namespace Magick;</FONT></TT>
52
<P><TT><FONT COLOR="#000066">int main(int /*argc*/,char **/*argv*/)</FONT></TT>
53
<BR><TT><FONT COLOR="#000066">{</FONT></TT> <BR><TT><FONT COLOR="#000066">
54
try {</FONT></TT> <BR><TT><FONT COLOR="#000066"> //
55
Create base image (white image of 300 by 200 pixels)</FONT></TT> <BR><TT><FONT COLOR="#000066">
56
Image image( Geometry(300,200), Color("white") );</FONT></TT>
58
<P><TT><FONT COLOR="#000066"> // Set draw options</FONT></TT>
59
<BR><TT><FONT COLOR="#000066">
60
image.strokeColor("red"); // Outline color</FONT></TT> <BR><TT><FONT COLOR="#000066">
61
image.fillColor("green"); // Fill color</FONT></TT> <BR><TT><FONT COLOR="#000066">
62
image.strokeWidth(5);</FONT></TT>
64
<P><TT><FONT COLOR="#000066"> // Draw a circle</FONT></TT>
65
<BR><TT><FONT COLOR="#000066"> image.draw(
66
DrawableCircle(100,100, 50,100) );</FONT></TT>
68
<P><TT><FONT COLOR="#000066"> // Draw a rectangle</FONT></TT>
69
<BR><TT><FONT COLOR="#000066"> image.draw(
70
DrawableRectangle(200,200, 270,170) );</FONT></TT>
72
<P><TT><FONT COLOR="#000066"> // Display the result</FONT></TT>
73
<BR><TT><FONT COLOR="#000066"> image.display( );</FONT></TT>
74
<BR><TT><FONT COLOR="#000066"> }</FONT></TT> <BR><TT><FONT COLOR="#000066">
75
catch( exception &error_ )</FONT></TT> <BR><TT><FONT COLOR="#000066">
76
{</FONT></TT> <BR><TT><FONT COLOR="#000066">
77
cout << "Caught exception: " << error_.what()
78
<< endl;</FONT></TT> <BR><TT><FONT COLOR="#000066">
79
return 1;</FONT></TT> <BR><TT><FONT COLOR="#000066">
82
<P><TT><FONT COLOR="#000066"> return 0;</FONT></TT> <BR><TT><FONT COLOR="#000066">}</FONT></TT>
84
<P><FONT COLOR="#000000">Since Drawable is an object it may be saved
85
in an array or a list for later (perhaps repeated) use. The following
86
example shows how to draw the same figure using the </FONT>list-based
89
<P><TT><FONT COLOR="#000066">#include <string></FONT></TT>
90
<BR><TT><FONT COLOR="#000066">#include <iostream></FONT></TT>
91
<BR><TT><FONT COLOR="#000066">#include <list></FONT></TT>
92
<BR><TT><FONT COLOR="#000066">#include <Magick++.h></FONT></TT>
94
<P><TT><FONT COLOR="#000066">using namespace std;</FONT></TT> <BR><TT><FONT COLOR="#000066">using
95
namespace Magick;</FONT></TT>
97
<P><TT><FONT COLOR="#000066">int main(int /*argc*/,char **/*argv*/)</FONT></TT>
98
<BR><TT><FONT COLOR="#000066">{</FONT></TT> <BR><TT><FONT COLOR="#000066">
99
try {</FONT></TT> <BR><TT><FONT COLOR="#000066"> //
100
Create base image (white image of 300 by 200 pixels)</FONT></TT> <BR><TT><FONT COLOR="#000066">
101
Image image( Geometry(300,200), Color("white") );</FONT></TT>
103
<P><TT><FONT COLOR="#000066"> // Construct drawing
104
list</FONT></TT> <BR><TT><FONT COLOR="#000066">
105
std::list<Magick::Drawable> drawList;</FONT></TT>
107
<P><TT><FONT COLOR="#000066"> // Add some drawing
108
options to drawing list</FONT></TT> <BR><TT><FONT COLOR="#000066">
109
drawList.push_back(DrawableStrokeColor("red")); // Outline
110
color</FONT></TT> <BR><TT><FONT COLOR="#000066">
111
drawList.push_back(DrawableStrokeWidth(5)); // Stroke width</FONT></TT>
112
<BR><TT><FONT COLOR="#000066">
113
drawList.push_back(DrawableFillColor("green")); // Fill
116
<P><TT><FONT COLOR="#000066"> // Add a Circle to
117
drawing list</FONT></TT> <BR><TT><FONT COLOR="#000066">
118
drawList.push_back(DrawableCircle(100,100, 50,100));</FONT></TT>
120
<P><TT><FONT COLOR="#000066"> // Add a Rectangle to
121
drawing list</FONT></TT> <BR><TT><FONT COLOR="#000066">
122
drawList.push_back(DrawableRectangle(200,100, 270,170));</FONT></TT>
124
<P><TT><FONT COLOR="#000066"> // Draw everything
125
using completed drawing list</FONT></TT> <BR><TT><FONT COLOR="#000066">
126
image.draw(drawList);</FONT></TT>
128
<P><TT><FONT COLOR="#000066"> // Display the result</FONT></TT>
129
<BR><TT><FONT COLOR="#000066"> image.display( );</FONT></TT>
130
<BR><TT><FONT COLOR="#000066"> }</FONT></TT> <BR><TT><FONT COLOR="#000066">
131
catch( exception &error_ )</FONT></TT> <BR><TT><FONT COLOR="#000066">
132
{</FONT></TT> <BR><TT><FONT COLOR="#000066">
133
cout << "Caught exception: " << error_.what()
134
<< endl;</FONT></TT> <BR><TT><FONT COLOR="#000066">
135
return 1;</FONT></TT> <BR><TT><FONT COLOR="#000066">
138
<P><TT><FONT COLOR="#000066"> return 0;</FONT></TT> <BR><TT><FONT COLOR="#000066">}</FONT></TT>
140
<P STYLE="margin-bottom: 0in"><FONT COLOR="#000000">Drawable depends
141
on the simple Coordinate structure which represents a pair of x,y
142
coodinates. The methods provided by the Coordinate structure are
143
shown in the following table:</FONT>
145
<P ALIGN=CENTER STYLE="margin-bottom: 0in"><B>Coordinate Structure
147
<TABLE WIDTH=100% BORDER=1 CELLPADDING=2 CELLSPACING=2>
150
<P CLASS="western">Method/Member</P>
153
<P CLASS="western">Signature</P>
156
<P CLASS="western">Description</P>
161
<P CLASS="western" ALIGN=CENTER>Coordinate</P>
164
<P CLASS="western">void</P>
167
<P CLASS="western">Default Constructor</P>
172
<P CLASS="western">double x_, double y_</P>
175
<P CLASS="western">Constructor, setting <I>first</I> & <I>second</I></P>
180
<P CLASS="western" ALIGN=CENTER>x</P>
183
<P CLASS="western">double x_</P>
186
<P CLASS="western">x coordinate member</P>
191
<P CLASS="western" ALIGN=CENTER>y</P>
194
<P CLASS="western">double y_</P>
197
<P CLASS="western">y coordinate member</P>
201
<P STYLE="margin-bottom: 0in"><FONT COLOR="#000000">The Drawable
202
classes are shown in the following table. Only constructor signatures
203
are documented here. Each Drawable class also provides methods by
204
which each individual parameter may be adjusted.</FONT>
206
<P ALIGN=CENTER STYLE="margin-bottom: 0in"><B>Drawable Classes</B></P>
207
<TABLE WIDTH=100% BORDER=1 CELLPADDING=2 CELLSPACING=3>
213
<P CLASS="western">Sub-Class</P>
216
<P CLASS="western">Constructor Signature</P>
219
<P CLASS="western">Description</P>
223
<TD ROWSPAN=2 WIDTH=27%>
224
<P CLASS="western" ALIGN=CENTER>DrawableAffine</P>
227
<P CLASS="western">double sx_, double sy_, double rx_, double ry_,
228
double tx_, double ty_</P>
231
<P CLASS="western">Specify a transformation matrix to adjust
232
scaling, rotation, and translation (coordinate transformation) for
233
subsequently drawn objects in the same or decendent drawing
234
context. The sx_ & sy_ parameters represent the x &
235
y scale factors, the rx_ & ry_ parameters represent the x &
236
y rotation, and the tx_ & ty_ parameters represent the x &
242
<P CLASS="western">void</P>
245
<P CLASS="western">Specify a transformation matrix to adjust
246
scaling, rotation, and translation (coordinate transformation) for
247
subsequently drawn objects in the same or decendent drawing
248
context. Initialized to unity (no effect) affine values. Use class
249
methods (not currently documented) to adjust individual parameters
250
from their unity values.</P>
255
<P CLASS="western" ALIGN=CENTER>DrawableAngle</P>
258
<P CLASS="western">double angle_</P>
261
<P CLASS="western">Set drawing angle</P>
266
<P CLASS="western" ALIGN=CENTER>DrawableArc</P>
269
<P CLASS="western">double startX_, double startY_, double endX_,
270
double endY_, double startDegrees, double endDegrees_</P>
273
<P CLASS="western">Draw an arc using the <I>stroke</I> color and
274
based on the circle starting at coordinates <I>startX_</I>,<I>startY_,</I>
275
and ending with coordinates <I>endX_,</I>endY_, and bounded by the
276
rotational arc <I>startDegrees_,endDegrees_</I></P>
281
<P CLASS="western" ALIGN=CENTER>DrawableBezier</P>
284
<P CLASS="western">const std::list<Magick::Coordinate>
285
&coordinates_</P>
288
<P CLASS="western">Draw a bezier curve using the <I>stroke</I>
289
color and based on the coordinates specified by the <I>coordinates_
295
<P CLASS="western" ALIGN=CENTER>DrawableClipPath</P>
298
<P CLASS="western">const std::string &id_</P>
301
<P CLASS="western">Select a drawing clip path matching <EM>id_.</EM></P>
306
<P CLASS="western" ALIGN=CENTER>DrawableCircle</P>
309
<P CLASS="western">double originX_, double originY_, double
310
perimX_, double perimY_</P>
313
<P CLASS="western">Draw a circle using the <I>stroke</I> color and
314
thickness using specified origin and perimeter coordinates. If a
315
<I>fill</I> color is specified, then the object is filled.</P>
320
<P CLASS="western" ALIGN=CENTER>DrawableColor</P>
323
<P CLASS="western"><FONT SIZE=2>double x_, double y_, <A HREF="Enumerations.html#PaintMethod">PaintMethod</A>
324
paintMethod_</FONT></P>
327
<P CLASS="western">Color image according to paintMethod. The point
328
method recolors the target pixel. The replace method
329
recolors any pixel that matches the color of the target pixel.
330
Floodfill recolors any pixel that matches the color of the target
331
pixel and is a neighbor, whereas filltoborder recolors any
332
neighbor pixel that is not the border color. Finally, reset
333
recolors all pixels.</P>
337
<TD ROWSPAN=6 WIDTH=27%>
338
<P CLASS="western" ALIGN=CENTER>DrawableCompositeImage</P>
341
<P CLASS="western">double x_, double y_, const std::string
344
<TD ROWSPAN=2 WIDTH=52%>
345
<P CLASS="western">Composite current image with contents of
346
specified image, at specified coordinates. If the <I>matte</I>
347
attribute is set to <I>true</I>, then the image composition will
348
consider an alpha channel, or transparency, present in the image
349
file so that non-opaque portions allow part (or all) of the
350
composite image to show through.</P>
355
<P CLASS="western">double x_, double y_, const Image &image_</P>
360
<P CLASS="western">double x_, double y_, double width_, double
361
height_, const std::string &filename_</P>
363
<TD ROWSPAN=2 WIDTH=52%>
364
<P CLASS="western">Composite current image with contents of
365
specified image, rendered with specified width and height, at
366
specified coordinates. If the <I>matte</I> attribute is set to
367
<I>true</I>, then the image composition will consider an alpha
368
channel, or transparency, present in the image file so that
369
non-opaque portions allow part (or all) of the composite image to
370
show through. If the specified <I>width</I> or <I>height</I> is
371
zero, then the image is composited at its natural size, without
372
enlargement or reduction.</P>
377
<P CLASS="western">double x_, double y_, double width_, double
378
height_, const Image &image_</P>
383
<P CLASS="western"><FONT SIZE=2>double x_, double y_, double
384
width_, double height_, const std::string &filename_,
385
<A HREF="Enumerations.html#CompositeOperator">CompositeOperator</A>
386
composition_</FONT></P>
388
<TD ROWSPAN=2 WIDTH=52%>
389
<P CLASS="western">Composite current image with contents of
390
specified image, rendered with specified width and height, using
391
specified composition algorithm, at specified coordinates. If the
392
<I>matte</I> attribute is set to <I>true</I>, then the image
393
composition will consider an alpha channel, or transparency,
394
present in the image file so that non-opaque portions allow part
395
(or all) of the composite image to show through. If the specified
396
<I>width</I> or <I>height</I> is zero, then the image is
397
composited at its natural size, without enlargement or reduction.</P>
402
<P CLASS="western"><FONT SIZE=2>double x_, double y_, double
403
width_, double height_, const Image &image_, <A HREF="Enumerations.html#CompositeOperator">CompositeOperator</A>
404
composition_</FONT></P>
409
<P CLASS="western" ALIGN=CENTER>DrawableDashArray</P>
412
<P CLASS="western">const double* dasharray_</P>
415
<P CLASS="western">Specify the pattern of dashes and gaps used to
416
stroke paths. The strokeDashArray represents a zero-terminated
417
array of numbers that specify the lengths of alternating dashes
418
and gaps in pixels. If an odd number of values is provided, then
419
the list of values is repeated to yield an even number of values.
420
A typical strokeDashArray_ array might contain the members 5 3 2
421
0, where the zero value indicates the end of the pattern array.</P>
426
<P CLASS="western" ALIGN=CENTER>DrawableDashOffset</P>
429
<P CLASS="western">double offset_</P>
432
<P CLASS="western"><FONT SIZE=2 STYLE="font-size: 11pt">Specify
433
the distance into the dash pattern to start the dash. See
434
documentation on SVG's </FONT><A HREF="http://www.w3.org/TR/SVG/painting.html#StrokeDashoffsetProperty"><FONT SIZE=2 STYLE="font-size: 11pt">stroke-dashoffset</FONT></A><FONT SIZE=2 STYLE="font-size: 11pt">
435
property for usage details.</FONT></P>
440
<P CLASS="western" ALIGN=CENTER>DrawableEllipse</P>
443
<P CLASS="western">double originX_, double originY_, double
444
radiusX_, double radiusY_, double arcStart_, double arcEnd_</P>
447
<P CLASS="western">Draw an ellipse using the <I>stroke</I> color
448
and thickness, specified origin, x & y radius, as well as
449
specified start and end of arc in degrees. If a <I>fill</I> color
450
is specified, then the object is filled.</P>
455
<P CLASS="western" ALIGN=CENTER>DrawableFillColor</P>
458
<P CLASS="western"><FONT SIZE=2>const <A HREF="Color.html">Color</A>
459
&color_</FONT></P>
462
<P CLASS="western">Specify drawing object fill color.</P>
467
<P CLASS="western" ALIGN=CENTER>DrawableFillRule</P>
470
<P CLASS="western"><FONT SIZE=2><A HREF="Enumerations.html#FillRule">FillRule</A>
474
<P CLASS="western"><FONT SIZE=2 STYLE="font-size: 11pt">Specify
475
the algorithm which is to be used to determine what parts of the
476
canvas are included inside the shape. See documentation on SVG's
477
</FONT><A HREF="http://www.w3.org/TR/SVG/painting.html#FillRuleProperty"><FONT SIZE=2 STYLE="font-size: 11pt">fill-rule</FONT></A><FONT SIZE=2 STYLE="font-size: 11pt">
478
property for usage details.</FONT></P>
483
<P CLASS="western" ALIGN=CENTER>DrawableFillOpacity</P>
486
<P CLASS="western">double opacity_</P>
489
<P CLASS="western">Specify opacity to use when drawing using fill
494
<TD ROWSPAN=2 WIDTH=27%>
495
<P CLASS="western" ALIGN=CENTER>DrawableFont</P>
498
<P CLASS="western">const std::string &font_</P>
501
<P CLASS="western">Specify font name to use when drawing text.</P>
506
<P CLASS="western"><FONT SIZE=2>const std::string &family_,</FONT>
507
<BR><FONT SIZE=2><A HREF="Enumerations.html#StyleType">StyleType</A>
508
style_,</FONT> <BR><FONT SIZE=2>unsigned long weight_,</FONT>
509
<BR><FONT SIZE=2><A HREF="Enumerations.html#StretchType">StretchType</A>
513
<P CLASS="western">Specify font family, style, weight (one of the
514
set { 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900 } with
515
400 being the normal size), and stretch to be used to select the
516
font used when drawing text. Wildcard matches may be applied to
517
style via the AnyStyle enumeration, applied to weight if weight is
518
zero, and applied to stretch via the AnyStretch enumeration.</P>
523
<P CLASS="western" ALIGN=CENTER>DrawableGravity</P>
526
<P CLASS="western"><FONT SIZE=2><A HREF="Enumerations.html#GravityType">GravityType</A>
530
<P CLASS="western">Specify text positioning gravity.</P>
535
<P CLASS="western" ALIGN=CENTER>DrawableLine</P>
538
<P CLASS="western">double startX_, double startY_, double endX_,
542
<P CLASS="western">Draw a line using <I>stroke</I> color and
543
thickness using starting and ending coordinates</P>
548
<P CLASS="western" ALIGN=CENTER>DrawableMatte</P>
551
<P CLASS="western"><FONT SIZE=2>double x_, double y_, <A HREF="Enumerations.html#PaintMethod">PaintMethod</A>
552
paintMethod_</FONT></P>
555
<P CLASS="western">Change the pixel matte value to transparent.
556
The point method changes the matte value of the target pixel.
557
The replace method changes the matte value of any pixel that
558
matches the color of the target pixel. Floodfill changes the matte
559
value of any pixel that matches the color of the target pixel and
560
is a neighbor, whereas filltoborder changes the matte value of any
561
neighbor pixel that is not the border color, Finally reset changes
562
the matte value of all pixels.</P>
567
<P CLASS="western" ALIGN=CENTER>DrawableMiterLimit</P>
570
<P CLASS="western">unsigned int miterLimit_</P>
573
<P CLASS="western">Specify miter limit. When two line segments
574
meet at a sharp angle and miter joins have been specified for
575
'lineJoin', it is possible for the miter to extend far beyond the
576
thickness of the line stroking the path. The miterLimit' imposes a
577
limit on the ratio of the miter length to the 'lineWidth'. The
578
default value of this parameter is 4.</P>
583
<P CLASS="western" ALIGN=CENTER>DrawablePath</P>
586
<P CLASS="western">const std::list<Magick::VPath> &path_</P>
589
<P CLASS="western">Draw on image using vector path.</P>
594
<P CLASS="western" ALIGN=CENTER>DrawablePoint</P>
597
<P CLASS="western">double x_, double y_</P>
600
<P CLASS="western">Draw a point using <I>stroke</I> color and
601
thickness at coordinate</P>
606
<P CLASS="western" ALIGN=CENTER>DrawablePointSize</P>
609
<P CLASS="western">double pointSize_</P>
612
<P CLASS="western">Set font point size.</P>
617
<P CLASS="western" ALIGN=CENTER>DrawablePolygon</P>
620
<P CLASS="western">const std::list<Magick::Coordinate>
621
&coordinates_</P>
624
<P CLASS="western">Draw an arbitrary polygon using <I>stroke</I>
625
color and thickness consisting of three or more coordinates
626
contained in an STL list. If a <I>fill</I> color is specified,
627
then the object is filled.</P>
632
<P CLASS="western" ALIGN=CENTER>DrawablePolyline</P>
635
<P CLASS="western">const std::list<Magick::Coordinate>
636
&coordinates_</P>
639
<P CLASS="western">Draw an arbitrary polyline using <I>stroke</I>
640
color and thickness consisting of three or more coordinates
641
contained in an STL list. If a <I>fill</I> color is specified,
642
then the object is filled.</P>
647
<P CLASS="western" ALIGN=CENTER>DrawablePopClipPath</P>
650
<P CLASS="western">void</P>
653
<P CLASS="western">Pop (terminate) clip path definition started by
654
DrawablePushClipPath.</P>
659
<P CLASS="western" ALIGN=CENTER>DrawablePopGraphicContext</P>
662
<P CLASS="western">void</P>
665
<P CLASS="western"><FONT SIZE=2 STYLE="font-size: 11pt">Pop
666
Graphic Context. Removing the current graphic context from the
667
graphic context stack restores the options to the values they had
668
prior to the preceding </FONT><A HREF="#DrawablePushGraphicContext"><I><FONT SIZE=2 STYLE="font-size: 11pt">DrawablePushGraphicContext</FONT></I></A><FONT SIZE=2 STYLE="font-size: 11pt">
669
operation.</FONT></P>
674
<P CLASS="western" ALIGN=CENTER>DrawablePushClipPath</P>
677
<P CLASS="western">const std::string &id_</P>
680
<P CLASS="western">Push (create) clip path definition with id_.
681
Clip patch definition consists of subsequent drawing commands,
682
terminated by DrawablePopClipPath.</P>
687
<P CLASS="western" ALIGN=CENTER>DrawablePushGraphicContext</P>
690
<P CLASS="western">void</P>
693
<P CLASS="western"><FONT SIZE=2 STYLE="font-size: 11pt">Push
694
Graphic Context. When a graphic context is pushed, options set
695
after the context is pushed (such as coordinate transformations,
696
color settings, etc.) are saved to a new graphic context. This
697
allows related options to be saved on a graphic context "stack"
698
in order to support heirarchical nesting of options. When
699
</FONT><A HREF="#DrawablePopGraphicContext"><I><FONT SIZE=2 STYLE="font-size: 11pt">DrawablePopGraphicContext</FONT></I></A><FONT SIZE=2 STYLE="font-size: 11pt">
700
is used to pop the current graphic context, the options in effect
701
during the last <I>DrawablePushGraphicContext</I> operation are
707
<P CLASS="western" ALIGN=CENTER>DrawablePushPattern</P>
710
<P CLASS="western">std::string &id_, long x_, long y_, long
711
width_, long height_</P>
714
<P CLASS="western"><FONT SIZE=2 STYLE="font-size: 11pt">Start a
715
pattern definition with arbitrary pattern name specified by <I>id_</I>,
716
pattern offset specified by <I>x_</I> and <I>y_</I>, and pattern
717
size specified by <I>width_</I> and <I>height_</I>. The pattern is
718
defined within the coordinate system defined by the specified
719
offset and size. Arbitrary drawing objects (including
720
</FONT><A HREF="#DrawableCompositeImage"><FONT SIZE=2 STYLE="font-size: 11pt">DrawableCompositeImage</FONT></A><FONT SIZE=2 STYLE="font-size: 11pt">)
721
may be specified between </FONT><A HREF="#DrawablePushPattern"><FONT SIZE=2 STYLE="font-size: 11pt">DrawablePushPattern</FONT></A><FONT SIZE=2 STYLE="font-size: 11pt">
722
and </FONT><A HREF="#DrawablePopPattern"><FONT SIZE=2 STYLE="font-size: 11pt">DrawablePopPattern</FONT></A><FONT SIZE=2 STYLE="font-size: 11pt">
723
in order to draw the pattern. Normally the pair
724
</FONT><A HREF="#DrawablePushGraphicContext"><FONT SIZE=2 STYLE="font-size: 11pt">DrawablePushGraphicContext</FONT></A><FONT SIZE=2 STYLE="font-size: 11pt">
725
& </FONT><A HREF="#DrawablePopGraphicContext"><FONT SIZE=2 STYLE="font-size: 11pt">DrawablePopGraphicContext</FONT></A><FONT SIZE=2 STYLE="font-size: 11pt">
726
are used to enclose a pattern definition. Pattern definitions are
727
terminated by a </FONT><A HREF="#DrawablePopPattern"><FONT SIZE=2 STYLE="font-size: 11pt">DrawablePopPattern</FONT></A><FONT SIZE=2 STYLE="font-size: 11pt">
733
<P CLASS="western" ALIGN=CENTER>DrawablePopPattern</P>
736
<P CLASS="western">void</P>
739
<P CLASS="western"><FONT SIZE=2 STYLE="font-size: 11pt">Terminate
740
a pattern definition started via </FONT><A HREF="#DrawablePushPattern"><FONT SIZE=2 STYLE="font-size: 11pt">DrawablePushPattern</FONT></A><FONT SIZE=2 STYLE="font-size: 11pt">.</FONT></P>
745
<P CLASS="western" ALIGN=CENTER>DrawableRectangle</P>
748
<P CLASS="western">double upperLeftX_, double upperLeftY_, double
749
lowerRightX_, double lowerRightY</P>
752
<P CLASS="western">Draw a rectangle using <I>stroke</I> color and
753
thickness from upper-left coordinates to lower-right coordinates.
754
If a <I>fill</I> color is specified, then the object is filled.</P>
759
<P CLASS="western" ALIGN=CENTER>DrawableRotation</P>
762
<P CLASS="western">double angle_</P>
765
<P CLASS="western">Set rotation to use when drawing (coordinate
771
<P CLASS="western" ALIGN=CENTER>DrawableRoundRectangle</P>
774
<P CLASS="western">double centerX_, double centerY_, double
775
width_, double hight_, double cornerWidth_, double cornerHeight_</P>
778
<P CLASS="western">Draw a rounded rectangle using <I>stroke</I>
779
color and thickness, with specified center coordinate, specified
780
width and height, and specified corner width and height. If
781
a <I>fill</I> color is specified, then the object is filled.</P>
786
<P CLASS="western" ALIGN=CENTER>DrawableScaling</P>
789
<P CLASS="western">double x_, double y_</P>
792
<P CLASS="western">Apply scaling in x and y direction while
793
drawing objects (coordinate transformation).</P>
798
<P CLASS="western" ALIGN=CENTER>DrawableSkewX</P>
801
<P CLASS="western">double angle_</P>
804
<P CLASS="western">Apply Skew in X direction (coordinate
810
<P CLASS="western" ALIGN=CENTER>DrawableSkewY</P>
813
<P CLASS="western">double angle_</P>
816
<P CLASS="western">Apply Skew in Y direction</P>
821
<P CLASS="western" ALIGN=CENTER>DrawableStrokeAntialias</P>
824
<P CLASS="western">bool flag_</P>
827
<P CLASS="western">Antialias while drawing lines or object
833
<P CLASS="western" ALIGN=CENTER>DrawableStrokeColor</P>
836
<P CLASS="western"><FONT SIZE=2>const <A HREF="Color.html">Color</A>
837
&color_</FONT></P>
840
<P CLASS="western">Set color to use when drawing lines or object
846
<P CLASS="western" ALIGN=CENTER>DrawableStrokeLineCap</P>
849
<P CLASS="western"><FONT SIZE=2><A HREF="Enumerations.html#LineCap">LineCap</A>
853
<P CLASS="western">Specify the shape to be used at the end of open
854
subpaths when they are stroked. Values of LineCap are
855
UndefinedCap, ButtCap, RoundCap, and SquareCap.</P>
860
<P CLASS="western" ALIGN=CENTER>DrawableStrokeLineJoin</P>
863
<P CLASS="western"><FONT SIZE=2><A HREF="Enumerations.html#LineJoin">LineJoin</A>
867
<P CLASS="western">Specify the shape to be used at the corners of
868
paths (or other vector shapes) when they are stroked. Values of
869
LineJoin are UndefinedJoin, MiterJoin, RoundJoin, and BevelJoin.</P>
874
<P CLASS="western" ALIGN=CENTER>DrawableStrokeOpacity</P>
877
<P CLASS="western">double opacity_</P>
880
<P CLASS="western">Opacity to use when drawing lines or object
886
<P CLASS="western" ALIGN=CENTER>DrawableStrokeWidth</P>
889
<P CLASS="western">double width_</P>
892
<P CLASS="western">Set width to use when drawing lines or object
897
<TD ROWSPAN=2 WIDTH=27%>
898
<P CLASS="western" ALIGN=CENTER>DrawableText</P>
901
<P CLASS="western">double x_, double y_, std::string text_</P>
904
<P CLASS="western"><FONT SIZE=2 STYLE="font-size: 11pt">Annotate
905
image with text using <I>stroke</I> color, font, font pointsize,
906
and <I>box</I> color (text background color), at specified
907
coordinates. If text contains </FONT><A HREF="FormatCharacters.html"><FONT SIZE=2 STYLE="font-size: 11pt">special
908
format characters</FONT></A><FONT SIZE=2 STYLE="font-size: 11pt">
909
the image filename, type, width, height, or other image attributes
910
may be incorporated in the text (see label()).</FONT></P>
915
<P CLASS="western">const double x_, const double y_, const
916
std::string &text_, const std::string &encoding_</P>
919
<P CLASS="western"><FONT SIZE=2 STYLE="font-size: 11pt">Annotate
920
image with text represented with text encoding, using current
921
<I>stroke</I> color, font, font pointsize, and <I>box</I> color
922
(text background color), at specified coordinates. If text
923
contains </FONT><A HREF="FormatCharacters.html"><FONT SIZE=2 STYLE="font-size: 11pt">special
924
format characters</FONT></A><FONT SIZE=2 STYLE="font-size: 11pt">
925
the image filename, type, width, height, or other image attributes
926
may be incorporated in the text (see label()).</FONT></P>
927
<P CLASS="western"><FONT SIZE=2 STYLE="font-size: 11pt">The text
928
encoding specifies the code set to use for text annotations. The
929
only character encoding which may be specified at this time is
930
"<FONT FACE="Courier, monospace">UTF-8</FONT>" for
931
representing </FONT><A HREF="http://www.unicode.org/"><FONT SIZE=2 STYLE="font-size: 11pt">Unicode</FONT></A><FONT SIZE=2 STYLE="font-size: 11pt">
932
as a sequence of bytes. Specify an empty string to set text
933
encoding to the system's default. Successful text annotation using
934
Unicode may require fonts designed to support Unicode.</FONT></P>
939
<P CLASS="western" ALIGN=CENTER>DrawableTextAntialias</P>
942
<P CLASS="western">bool flag_</P>
945
<P CLASS="western">Antialias while drawing text (default true).
946
The main reason to disable text antialiasing is to avoid adding
947
new colors to the image.</P>
952
<P CLASS="western" ALIGN=CENTER><A NAME="DrawableTextDecoration"></A>
953
DrawableTextDecoration</P>
956
<P CLASS="western"><FONT SIZE=2><A HREF="Enumerations.html#DecorationType">DecorationType</A>
957
decoration_</FONT></P>
960
<P CLASS="western">Specify decoration (e.g. UnderlineDecoration)
961
to apply to text.</P>
966
<P CLASS="western" ALIGN=CENTER>DrawableTextUnderColor</P>
969
<P CLASS="western">const Color &color_</P>
972
<P CLASS="western">Draw a box under rendered text using the
978
<P CLASS="western" ALIGN=CENTER>DrawableTranslation</P>
981
<P CLASS="western">double x_, double y_</P>
984
<P CLASS="western">Apply coordinate translation (set new
985
coordinate origin).</P>
990
<P CLASS="western" ALIGN=CENTER>DrawableViewbox</P>
993
<P CLASS="western">unsigned long x1_, unsigned long y1_, unsigned
994
long x2_, unsigned long y2_</P>
997
<P CLASS="western">Dimensions of the output viewbox. If the image
998
is to be written to a vector format (e.g. MVG or SVG), then a
999
DrawablePushGraphicContext() object should be pushed to the head
1000
of the list, followed by a DrawableViewbox() statement to
1001
establish the output canvas size. A matching
1002
DrawablePopGraphicContext() object should be pushed to the tail of
1007
<H2 ALIGN=CENTER>Vector Path Classes</H2>
1008
<P>The vector paths supported by Magick++ are based on those
1009
supported by the <A HREF="http://www.w3.org/TR/SVG/paths.html">SVG
1010
XML specification</A>. Vector paths are not directly drawable, they
1011
must first be supplied as a constructor argument to the <A HREF="#DrawablePath">DrawablePath</A>
1012
class in order to create a drawable object. The <A HREF="#DrawablePath">DrawablePath</A>
1013
class effectively creates a drawable compound component which may be
1014
replayed as desired. If the drawable compound component consists only
1015
of vector path objects using relative coordinates then the object may
1016
be positioned on the image by preceding it with a <I>DrawablePath</I>
1017
which sets the current drawing coordinate. Alternatively coordinate
1018
transforms may be used to <A HREF="#DrawableTranslation">translate
1019
the origin</A> in order to position the object, <A HREF="#DrawableRotation">rotate</A>
1020
it, <A HREF="#DrawableSkewX">skew</A> it, or <A HREF="#DrawableScaling">scale</A>
1023
<H3>The "moveto" commands</H3>
1024
<P STYLE="margin-bottom: 0in">The "moveto" commands
1025
establish a new current point. The effect is as if the "pen"
1026
were lifted and moved to a new location. A path data segment must
1027
begin with either one of the "moveto" commands or one of
1028
the "arc" commands. Subsequent "moveto" commands
1029
(i.e., when the "moveto" is not the first command)
1030
represent the start of a new subpath:
1032
<P ALIGN=CENTER STYLE="margin-bottom: 0in"><B>Moveto Classes</B></P>
1033
<TABLE WIDTH=100% BORDER=1 CELLPADDING=2 CELLSPACING=3>
1039
<P CLASS="western">Sub-Class</P>
1042
<P CLASS="western">Constructor Signature</P>
1045
<P CLASS="western">Description</P>
1049
<TD ROWSPAN=2 WIDTH=14%>
1050
<P CLASS="western" ALIGN=CENTER><A NAME="PathMovetoAbs"></A>PathMovetoAbs</P>
1053
<P CLASS="western">const Magick::Coordinate &coordinate_</P>
1055
<TD ROWSPAN=4 WIDTH=69%>
1056
<P CLASS="western">Start a new sub-path at the given coordinate.
1057
<I>PathMovetoAbs</I> indicates that absolute coordinates will
1058
follow; <I>PathMovetoRel</I> indicates that relative coordinates
1059
will follow. If a relative moveto appears as the first element of
1060
the path, then it is treated as a pair of absolute coordinates. If
1061
a moveto is followed by multiple pairs of coordinates, the
1062
subsequent pairs are treated as implicit lineto commands.</P>
1067
<P CLASS="western">const std::list<Magick::Coordinate>
1068
&coordinates_</P>
1072
<TD ROWSPAN=2 WIDTH=14%>
1073
<P CLASS="western" ALIGN=CENTER><A NAME="PathMovetoRel"></A>PathMovetoRel</P>
1076
<P CLASS="western">const Magick::Coordinate &coordinate_</P>
1081
<P CLASS="western">const std::list<Magick::Coordinate>
1082
&coordinates_</P>
1086
<H3>The "closepath" command</H3>
1087
<P STYLE="margin-bottom: 0in">The "closepath" command
1088
causes an automatic straight line to be drawn from the current point
1089
to the initial point of the current subpath:
1091
<P ALIGN=CENTER STYLE="margin-bottom: 0in"><B>Closepath Classes</B></P>
1092
<TABLE WIDTH=100% BORDER=1 CELLPADDING=2 CELLSPACING=3>
1098
<P CLASS="western">Sub-Class</P>
1101
<P CLASS="western">Constructor Signature</P>
1104
<P CLASS="western">Description</P>
1109
<P CLASS="western" ALIGN=CENTER><A NAME="PathClosePath"></A>PathClosePath</P>
1112
<P CLASS="western">void</P>
1115
<P CLASS="western">Close the current subpath by drawing a straight
1116
line from the current point to current subpath's most recent
1117
starting point (usually, the most recent moveto point).</P>
1121
<H3>The "lineto" commands</H3>
1122
<P STYLE="margin-bottom: 0in">The various "lineto" commands
1123
draw straight lines from the current point to a new point:
1125
<P ALIGN=CENTER STYLE="margin-bottom: 0in"><B>Lineto Classes</B></P>
1126
<TABLE WIDTH=100% BORDER=1 CELLPADDING=2 CELLSPACING=3>
1132
<P CLASS="western">Sub-Class</P>
1135
<P CLASS="western">Constructor Signature</P>
1138
<P CLASS="western">Description</P>
1142
<TD ROWSPAN=2 WIDTH=22%>
1143
<P CLASS="western" ALIGN=CENTER><A NAME="PathLinetoAbs"></A>PathLinetoAbs</P>
1146
<P CLASS="western">const Magick::Coordinate& coordinate_</P>
1148
<TD ROWSPAN=4 WIDTH=63%>
1149
<P CLASS="western">Draw a line from the current point to the given
1150
coordinate which becomes the new current point.
1151
<I>PathLinetoAbs</I> indicates that absolute coordinates are used;
1152
<I>PathLinetoRel</I> indicates that relative coordinates are used.
1153
A number of coordinates pairs may be specified in a list to draw a
1154
polyline. At the end of the command, the new current point is set
1155
to the final set of coordinates provided.</P>
1160
<P CLASS="western">const std::list<Magick::Coordinate>
1161
&coordinates_</P>
1165
<TD ROWSPAN=2 WIDTH=22%>
1166
<P CLASS="western" ALIGN=CENTER><A NAME="PathLinetoRel"></A>PathLinetoRel</P>
1169
<P CLASS="western">const Magick::Coordinate& coordinate_</P>
1174
<P CLASS="western">const std::list<Magick::Coordinate>
1175
&coordinates_</P>
1180
<P CLASS="western" ALIGN=CENTER><A NAME="PathLinetoHorizontalAbs"></A>
1181
PathLinetoHorizontalAbs</P>
1184
<P CLASS="western">double x_</P>
1186
<TD ROWSPAN=2 WIDTH=63%>
1187
<P CLASS="western">Draws a horizontal line from the current point
1188
(cpx, cpy) to (x, cpy). <I>PathLinetoHorizontalAbs</I> indicates
1189
that absolute coordinates are supplied; <I>PathLinetoHorizontalRel</I>
1190
indicates that relative coordinates are supplied. At the end of
1191
the command, the new current point becomes (x, cpy) for the final
1197
<P CLASS="western" ALIGN=CENTER><A NAME="PathLinetoHorizontalRel"></A>
1198
PathLinetoHorizontalRel</P>
1201
<P CLASS="western">double x_</P>
1206
<P CLASS="western" ALIGN=CENTER><A NAME="PathLinetoVerticalAbs"></A>
1207
PathLinetoVerticalAbs</P>
1210
<P CLASS="western">double y_</P>
1212
<TD ROWSPAN=2 WIDTH=63%>
1213
<P CLASS="western">Draws a vertical line from the current point
1214
(cpx, cpy) to (cpx, y). <I>PathLinetoVerticalAbs</I> indicates
1215
that absolute coordinates are supplied; <I>PathLinetoVerticalRel</I>
1216
indicates that relative coordinates are supplied. At the end
1217
of the command, the new current point becomes (cpx, y) for the
1218
final value of y.</P>
1223
<P CLASS="western" ALIGN=CENTER><A NAME="PathLinetoVerticalRel"></A>
1224
PathLinetoVerticalRel</P>
1227
<P CLASS="western">double y_</P>
1231
<H3>The curve commands</H3>
1232
<P>These three groups of commands draw curves:
1235
<LI><P STYLE="margin-bottom: 0in"><A HREF="#cubic Bezier">Cubic
1236
Bézier commands.</A> A cubic Bézier segment is defined
1237
by a start point, an end point, and two control points.
1239
<LI><P STYLE="margin-bottom: 0in"><A HREF="#quadratic Bezier">Quadratic
1240
Bézier commands.</A> A quadratic Bézier segment is
1241
defined by a start point, an end point, and one control point.
1243
<LI><P><A HREF="#elliptical arc">Elliptical arc commands.</A> An
1244
elliptical arc segment draws a segment of an ellipse.
1247
<H3><A NAME="cubic Bezier"></A>The cubic Bézier curve
1249
<P>The cubic Bézier commands depend on the <I>PathCurvetoArgs</I>
1250
argument class, which has the constructor signature
1252
<P><TT> PathCurvetoArgs( double x1_, double y1_,</TT>
1253
<BR><TT>
1254
double x2_, double y2_,</TT> <BR><TT>
1255
double x_, double y_ );</TT>
1257
<P STYLE="margin-bottom: 0in">The commands are as follows:
1259
<P ALIGN=CENTER STYLE="margin-bottom: 0in"><B>Cubic Bézier
1260
Curve Classes</B></P>
1261
<TABLE WIDTH=100% BORDER=1 CELLPADDING=2 CELLSPACING=3>
1267
<P CLASS="western">Sub-Class</P>
1270
<P CLASS="western">Constructor Signature</P>
1273
<P CLASS="western">Description</P>
1277
<TD ROWSPAN=2 WIDTH=21%>
1278
<P CLASS="western" ALIGN=CENTER><A NAME="PathCurvetoAbs"></A>PathCurvetoAbs</P>
1281
<P CLASS="western">const Magick::PathCurvetoArgs &args_</P>
1283
<TD ROWSPAN=4 WIDTH=56%>
1284
<P CLASS="western">Draws a cubic Bézier curve from the
1285
current point to (x,y) using (x1,y1) as the control point at the
1286
beginning of the curve and (x2,y2) as the control point at the end
1287
of the curve. <I>PathCurvetoAbs</I> indicates that
1288
absolutecoordinates will follow; <I>PathCurvetoRel</I> indicates
1289
that relative coordinates will follow. Multiple sets of
1290
coordinates may be specified to draw a polybezier. At the end of
1291
the command, the new current point becomes the final (x,y)
1292
coordinate pair used in the polybezier.</P>
1297
<P CLASS="western">const std::list<Magick::PathCurvetoArgs>
1302
<TD ROWSPAN=2 WIDTH=21%>
1303
<P CLASS="western" ALIGN=CENTER><A NAME="PathCurvetoRel"></A>PathCurvetoRel</P>
1306
<P CLASS="western">const Magick::PathCurvetoArgs &args_</P>
1311
<P CLASS="western">const std::list<Magick::PathCurvetoArgs>
1316
<TD ROWSPAN=2 WIDTH=21%>
1317
<P CLASS="western" ALIGN=CENTER><A NAME="PathSmoothCurvetoAbs"></A>
1318
PathSmoothCurvetoAbs</P>
1321
<P CLASS="western">const Magick::Coordinate &coordinates_</P>
1323
<TD ROWSPAN=4 WIDTH=56%>
1324
<P CLASS="western">Draws a cubic Bézier curve from the
1325
current point to (x,y). The first control point is assumed to be
1326
the reflection of the second control point on the previous command
1327
relative to the current point. (If there is no previous command or
1328
if the previous command was not an <I>PathCurvetoAbs</I>,
1329
<I>PathCurvetoRel</I>, <I>PathSmoothCurvetoAbs</I> or
1330
<I>PathSmoothCurvetoRel</I>, assume the first control point is
1331
coincident with the current point.) (x2,y2) is the second control
1332
point (i.e., the control point at the end of the curve).
1333
<I>PathSmoothCurvetoAbs</I> indicates that absolute coordinates
1334
will follow; <I>PathSmoothCurvetoRel</I> indicates that
1335
relative coordinates will follow. Multiple sets of coordinates may
1336
be specified to draw a polybezier. At the end of the command, the
1337
new current point becomes the final (x,y) coordinate pair used in
1343
<P CLASS="western">const std::list<Magick::Coordinate>
1344
&coordinates_</P>
1348
<TD ROWSPAN=2 WIDTH=21%>
1349
<P CLASS="western" ALIGN=CENTER><A NAME="PathSmoothCurvetoRel"></A>
1350
PathSmoothCurvetoRel</P>
1353
<P CLASS="western">const Magick::Coordinate &coordinates_</P>
1358
<P CLASS="western">const std::list<Magick::Coordinate>
1359
&coordinates_</P>
1363
<H3><A NAME="quadratic Bezier"></A>The quadratic Bézier curve
1365
<P>The quadratic Bézier commands depend on the
1366
<I>PathQuadraticCurvetoArgs</I> argument class, which has the
1367
constructor signature:
1369
<P><TT> PathQuadraticCurvetoArgs( double x1_, double y1_,</TT>
1370
<BR><TT>
1371
double x_, double y_ );</TT>
1373
<P STYLE="margin-bottom: 0in">The quadratic Bézier commands
1376
<P ALIGN=CENTER STYLE="margin-bottom: 0in"><B>Quadratic Bézier
1377
Curve Classes</B></P>
1378
<TABLE WIDTH=100% BORDER=1 CELLPADDING=2 CELLSPACING=2>
1381
<P CLASS="western">Sub-Class</P>
1384
<P CLASS="western">Constructor Signature</P>
1387
<P CLASS="western">Description</P>
1392
<P CLASS="western" ALIGN=CENTER><A NAME="PathQuadraticCurvetoAbs"></A>
1393
PathQuadraticCurvetoAbs</P>
1396
<P CLASS="western">const Magick::PathQuadraticCurvetoArgs &args_</P>
1399
<P CLASS="western">Draws a quadratic Bézier curve from the
1400
current point to (x,y) using (x1,y1) as the control point.
1401
<I>PathQuadraticCurvetoAbs</I> indicates that absolute coordinates
1402
will follow; <I>PathQuadraticCurvetoRel</I> indicates that
1403
relative coordinates will follow. Multiple sets of coordinates may
1404
be specified to draw a polybezier. At the end of the command, the
1405
new current point becomes the final (x,y) coordinate pair used in
1411
<P CLASS="western">const
1412
std::list<Magick::PathQuadraticCurvetoArgs> &args_</P>
1417
<P CLASS="western" ALIGN=CENTER><A NAME="PathQuadraticCurvetoRel"></A>
1418
PathQuadraticCurvetoRel</P>
1421
<P CLASS="western">const Magick::PathQuadraticCurvetoArgs &args_</P>
1426
<P CLASS="western">const
1427
std::list<Magick::PathQuadraticCurvetoArgs> &args_</P>
1432
<P CLASS="western" ALIGN=CENTER><A NAME="PathSmoothQuadraticCurvetoAbs"></A>
1433
PathSmoothQuadraticCurvetoAbs</P>
1436
<P CLASS="western">const Magick::Coordinate &coordinate_</P>
1439
<P CLASS="western">Draws a quadratic Bézier curve from the
1440
current point to (x,y). The control point is assumed to be the
1441
reflection of the control point on the previous <BR>command
1442
relative to the current point. (If there is no previous command or
1443
if the previous command was not a <I>PathQuadraticCurvetoAbs</I>,
1444
<I>PathQuadraticCurvetoRel</I>, <I>PathSmoothQuadraticCurvetoAbs</I>
1445
or <I>PathSmoothQuadraticCurvetoRel</I>, assume the control point
1446
is coincident with the current point.)
1447
<I>PathSmoothQuadraticCurvetoAbs</I> indicates that absolute
1448
coordinates will follow; <I>PathSmoothQuadraticCurvetoRel</I>
1449
indicates that relative coordinates will follow. At the end of the
1450
command, the new current point becomes the final (x,y) coordinate
1451
pair used in the polybezier.</P>
1456
<P CLASS="western">const std::list<Magick::Coordinate>
1457
&coordinates_</P>
1462
<P CLASS="western" ALIGN=CENTER><A NAME="PathSmoothQuadraticCurvetoRel"></A>
1463
PathSmoothQuadraticCurvetoRel</P>
1466
<P CLASS="western">const Magick::Coordinate &coordinate_</P>
1471
<P CLASS="western">const std::list<Magick::Coordinate>
1472
&coordinates_</P>
1476
<H3><A NAME="elliptical arc"></A>The elliptical arc curve commands</H3>
1477
<P>The elliptical arc curve commands depend on the <I>PathArcArgs</I>
1478
argument class, which has the constructor signature:
1480
<P><TT> PathArcArgs( double radiusX_, double radiusY_,</TT>
1481
<BR><TT>
1482
double xAxisRotation_, bool largeArcFlag_,</TT> <BR><TT>
1483
bool sweepFlag_, double x_, double y_ );</TT>
1485
<P STYLE="margin-bottom: 0in">The elliptical arc commands are as
1488
<P ALIGN=CENTER STYLE="margin-bottom: 0in"><B>Elliptical Arc Curve
1490
<TABLE WIDTH=100% BORDER=1 CELLPADDING=2 CELLSPACING=3>
1496
<P CLASS="western">Sub-Class</P>
1499
<P CLASS="western">Constructor Signature</P>
1502
<P CLASS="western">Description</P>
1506
<TD ROWSPAN=2 WIDTH=14%>
1507
<P CLASS="western" ALIGN=CENTER><A NAME="PathArcAbs"></A>PathArcAbs</P>
1510
<P CLASS="western">const Magick::PathArcArgs &coordinates_</P>
1512
<TD ROWSPAN=4 WIDTH=68%>
1513
<P CLASS="western">Draws an elliptical arc from the current point
1514
to (x, y). The size and orientation of the ellipse are defined by
1515
two radii (<I>radiusX</I>, <I>radiusY</I>) and an <I>xAxisRotation</I>,
1516
which indicates how the ellipse as a whole is rotated relative to
1517
the current coordinate system. The center (cx, cy) of the ellipse
1518
is calculated automatically to satisfy the constraints imposed by
1519
the other parameters. <I>largeArcFlag</I> and <I>sweepFlag</I>
1520
contribute to the automatic calculations and help determine how
1521
the arc is drawn. If <I>largeArcFlag</I> is true then draw the
1522
larger of the available arcs. If <I>sweepFlag</I> is true, then
1523
draw the arc matching a clock-wise rotation.</P>
1528
<P CLASS="western">const std::list<Magick::PathArcArgs>
1529
&coordinates_</P>
1533
<TD ROWSPAN=2 WIDTH=14%>
1534
<P CLASS="western" ALIGN=CENTER><A NAME="PathArcRel"></A>PathArcRel</P>
1537
<P CLASS="western">const Magick::PathArcArgs &coordinates_</P>
1542
<P CLASS="western">const std::list<Magick::PathArcArgs>
1543
&coordinates_</P>
b'\\ No newline at end of file'