1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152
|
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Name: graphicspath.tex
%% Purpose: wxGraphicsPath class documentation
%% Author: Stefan Csomor
%% Modified by:
%% Created: 08.06.2004
%% RCS-ID: $Id: graphicspath.tex 50200 2007-11-23 20:45:59Z VS $
%% Copyright: (c) Stefan Csomor
%% License: wxWindows license
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{\class{wxGraphicsPath}}\label{wxgraphicspath}
A wxGraphicsPath is a native representation of an geometric path. The contents are specific an private to the respective renderer. Instances are ref counted and can
therefore be assigned as usual. The only way to get a valid instance is via a CreatePath call on the graphics context or the renderer instance.
\wxheading{Derived from}
\helpref{wxGraphicsObject}{wxgraphicsobject}
\wxheading{Include files}
<wx/graphics.h>
\latexignore{\rtfignore{\wxheading{Members}}}
\membersection{wxGraphicsPath::MoveToPoint}\label{wxgraphicspathmovetopoint}
\func{void}{MoveToPoint}{\param{wxDouble }{x}, \param{wxDouble }{y}}
\func{void}{MoveToPoint}{\param{const wxPoint2DDouble\& }{p}}
Begins a new subpath at (x,y)
\membersection{wxGraphicsPath::AddArc}\label{wxgraphicspathaddarc}
\func{void}{AddArc}{\param{wxDouble }{x}, \param{wxDouble }{y}, \param{wxDouble }{r}, \param{wxDouble }{startAngle}, \param{wxDouble }{endAngle},
\param{bool }{clockwise}}
Adds an arc of a circle centering at (x,y) with radius (r) from startAngle to endAngle.
\func{void}{AddArc}{\param{const wxPoint2DDouble\& }{c}, \param{wxDouble }{r}, \param{wxDouble }{startAngle}, \param{wxDouble }{endAngle},
\param{bool }{clockwise}}
\membersection{wxGraphicsPath::AddArcToPoint}\label{wxgraphicspathaddarctopoint}
\func{void}{AddArcToPoint}{\param{wxDouble }{x1}, \param{wxDouble }{y1}, \param{wxDouble }{x2}, \param{wxDouble }{y2}, \param{wxDouble }{r}}
Appends a an arc to two tangents connecting (current) to (x1,y1) and (x1,y1) to (x2,y2), also a straight line from (current) to (x1,y1).
\membersection{wxGraphicsPath::AddCircle}\label{wxgraphicspathaddcircle}
\func{void}{AddCircle}{\param{wxDouble }{x}, \param{wxDouble }{y}, \param{wxDouble }{r}}
Appends a circle around (x,y) with radius r as a new closed subpath.
\membersection{wxGraphicsPath::AddCurveToPoint}\label{wxgraphicspathaddcurvetopoint}
\func{void}{AddCurveToPoint}{\param{wxDouble }{cx1}, \param{wxDouble }{cy1}, \param{wxDouble }{cx2}, \param{wxDouble }{cy2}, \param{wxDouble }{x},
\param{wxDouble }{y}}
Adds a cubic Bezier curve from the current point, using two control points and an end point.
\func{void}{AddCurveToPoint}{\param{const wxPoint2DDouble\& }{c1}, \param{const wxPoint2DDouble\& }{c2}, \param{const wxPoint2DDouble\& }{e}}
\membersection{wxGraphicsPath::AddEllipse}\label{wxgraphicspathaddellipse}
\func{void}{AddEllipse}{\param{wxDouble }{x}, \param{wxDouble }{y}, \param{wxDouble }{w}, \param{wxDouble }{h}}
Appends an ellipse fitting into the passed in rectangle.
\membersection{wxGraphicsPath::AddLineToPoint}\label{wxgraphicspathaddlinetopoint}
\func{void}{AddLineToPoint}{\param{wxDouble }{x}, \param{wxDouble }{y}}
Adds a straight line from the current point to (x,y).
\func{void}{AddLineToPoint}{\param{const wxPoint2DDouble\& }{p}}
\membersection{wxGraphicsPath::AddPath}\label{wxgraphicspathaddpath}
\func{void}{AddPath}{\param{const wxGraphicsPath\& }{path}}
Adds another path.
\membersection{wxGraphicsPath::AddQuadCurveToPoint}\label{wxgraphicspathaddquadcurvetopoint}
\func{void}{AddQuadCurveToPoint}{\param{wxDouble }{cx}, \param{wxDouble }{cy}, \param{wxDouble }{x}, \param{wxDouble }{y}}
Adds a quadratic Bezier curve from the current point, using a control point and an end point.
\membersection{wxGraphicsPath::AddRectangle}\label{wxgraphicspathaddrectangle}
\func{void}{AddRectangle}{\param{wxDouble }{x}, \param{wxDouble }{y}, \param{wxDouble }{w}, \param{wxDouble }{h}}
Appends a rectangle as a new closed subpath.
\membersection{wxGraphicsPath::AddRoundedRectangle}\label{wxgraphicspathaddroundedrectangle}
\func{void}{AddRoundedRectangle}{\param{wxDouble }{x}, \param{wxDouble }{y}, \param{wxDouble }{w}, \param{wxDouble }{h}, \param{wxDouble }{radius}}
Appends a rounded rectangle as a new closed subpath.
\membersection{wxGraphicsPath::CloseSubpath}\label{wxgraphicspathclosesubpath}
\func{void}{CloseSubpath}{\void}
Closes the current sub-path.
\membersection{wxGraphicsPath::Contains}\label{wxgraphicspathcontains}
\constfunc{bool}{Contains}{\param{const wxPoint2DDouble\& }{c}, \param{int }{fillStyle = wxODDEVEN\_RULE}}
\constfunc{bool}{Contains}{\param{wxDouble }{x}, \param{wxDouble }{y}, \param{int }{fillStyle = wxODDEVEN\_RULE}}
Returns true if the point is within the path.
\membersection{wxGraphicsPath::GetBox}\label{wxgraphicspathgetbox}
\constfunc{wxRect2DDouble}{GetBox}{\void}
\constfunc{void}{GetBox}{\param{wxDouble* }{x}, \param{wxDouble* }{y}, \param{wxDouble* }{w}, \param{wxDouble* }{h}}
Gets the bounding box enclosing all points (possibly including control points).
\membersection{wxGraphicsPath::GetCurrentPoint}\label{wxgraphicspathgetcurrentpoint}
\constfunc{void}{GetCurrentPoint}{\param{wxDouble* }{x}, \param{wxDouble* }{y}}
\constfunc{wxPoint2DDouble}{GetCurrentPoint}{\void}
Gets the last point of the current path, (0,0) if not yet set.
\membersection{wxGraphicsPath::Transform}\label{wxgraphicspathtransform}
\func{void}{Transform}{\param{const wxGraphicsMatrix\& }{matrix}}
Transforms each point of this path by the matrix.
\membersection{wxGraphicsPath::GetNativePath}\label{wxgraphicspathgetnativepath}
\constfunc{void *}{GetNativePath}{\void}
Returns the native path (CGPathRef for Core Graphics, Path pointer for GDIPlus and a cairo\_path\_t pointer for cairo).
\membersection{wxGraphicsPath::UnGetNativePath}\label{wxgraphicspathungetnativepath}
\constfunc{void}{UnGetNativePath}{\param{void* }{p}}
Gives back the native path returned by GetNativePath() because there might be some deallocations necessary (eg on cairo the native path returned by
GetNativePath is newly allocated each time).
|