StartAngle specifies the angle, in degrees, measured clockwise, from the x-axis to the line passing through the Center point of the ellipse and intersects the ellipse in the starting point of the arc. SweepAngle specifies the angle, in degrees, measured clockwise, from the StartAngle parameter to the line passing through the Center point of the ellipse and intersects the ellipse in the ending point of the arc. If there are previous lines or curves in the current TRSPathData, a line is added to connect the last point of the previous segment to the start point of the arc. To move the start point of the arc, call MoveTo or MoveToRel before calling AddArc. AddArc splits the arc in simple figures and adds to Points the points needed to represent them. The added points have different types. To find the last point of the TRSPathData, call the LastPoint method. |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
AddArcSvg(TRSPoint,TRSPoint,Single,Boolean,Boolean,TRSPoint) |
Represents method AddArcSvg(TRSPoint,TRSPoint,Single,Boolean,Boolean,TRSPoint). |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Appends an ellipse defined by a bounding rectangle structure to the current TRSPathData. AddEllipse splits the ellipse in simple figures and adds to Points the points needed to represent them. To find the end point of the TRSPathData, call the LastPoint method. |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Adds a crude outline around the input path to the current path.
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Overloaded. Adds the polygon to the current path. |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Overloaded. Adds the polygon to the current path. |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Overloaded. Adds the array of polygons to the current path. |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Overloaded. Adds the array of polygons to the current path. |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Overloaded. Adds a rectangle to the current TRSPathData. |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
AddRectangle(TRSRect,Single,Single,TRSCorners,TRSCornerType) |
Overloaded. Adds a rectangle with customized shapes of corners to the current TRSPathData. AddRectangle splits the rectangle in simple figures and adds the points needed to represent them to the Points array. The added points have appropriate types to represent the figures. To find the end point of the TRSPathData, call the LastPoint method. |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Represents method AddRectangleForSegment(TRSPoint,TRSPoint,Single). |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Overloaded. Appends the source path to the current path |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Overloaded. Appends the source path to the current path |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Applies a transformation matrix to the current TRSPathData. The transformation can translate, scale, or rotate the current TRSPathData. |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Represents method Assign(TPersistent). |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Defers OnChanged events until EndUpdate is called. BeginUpdate and EndUpdate work to defer OnChanged events while a path is being modified. Use the BeginUpdate method to defer OnChanged events until an equal number of EndUpdate methods have been called. |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Calculates the distance to every point in the path. Returns the length of the path.
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Called when the path changes. The Change method triggers an OnChanged event. |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Clears the current TRSPathData. Clear removes all the figures from the current TRSPathData. It clears the Points array. |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Creates a copy of the path data object.
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Closes the current TRSPathData. A closed path is a path for which the start point and the LastPoint coincide. The start point of a TRSPathData is the first point in the Points array. ClosePath adds the start point of the TRSPathData at the end of the Points array. The added point if of type ppClose. |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Appends a curve to the current TRSPathData. The curve is defined by 4 points: • A start point--the last point of the TPathData. • Two control points, specified by the ControlPoint1 and ControlPoint2 parameters. • An end point, specified by the EndPoint parameter. |
CurveTo adds the control points and the end point of the curve to the Points array. The added points are of type ppCurveTo.
To move the start point of the curve, call the MoveTo or MoveToRel method before calling CurveTo.
To find the end point of the TRSPathData, call the LastPoint method.
CurveToRel(TRSPoint,TRSPoint,TRSPoint)
Appends a curve to the current TRSPathData.
The curve is defined by 4 points that depend on the last point of the current TRSPathData.
The start point of the curve is the end point of the TRSPathData.
The ControlPoint1 and ControlPoint2 parameters' coordinates specify the distances to the end point of the current TRSPathData, on each axis, for each of the two control points of the curve.
The EndPoint parameter's coordinates specify the distances to the end point of the current TRSPathData, on each axis, for the end point of the curve.
CurveToRel adds the control points and the end point of the curve to the Points array. The coordinates for each added point are equal to the sum between the coordinates of the last point and the coordinates of the corresponding point specified by the parameters. The added points are of type ppCurveTo.
To move the start point of the curve, call the MoveTo or MoveToRel method before calling CurveToRel.
To find the end point of the TRSPathData, call the LastPoint method.
Sets the virtual properties for reading and writing the path data stream.
DefineProperties overrides TPersistent.DefineProperties for reading and writing path data from or to a TStream object, respectively.
It creates a virtual property, Path, that can be treated as a property to read from or write data to the TRSPathData object. It first calls the TPersistent.DefineProperties inherited method.
DrawPath(TCanvas,Boolean,Single)
Overloaded. Draws or Fills the path to the canvas.
Overloaded. Draws a path on the current TCanvas.
DrawPath draw a TRSPathData, with the current Stroke or Pen.
If the path is empty, DrawPath does nothing. In this case, DrawPath does not raise any errors.
Reenables OnChanged events after BeginUpdate has been called.
BeginUpdate and EndUpdate work to defer OnChanged events while a path is being modified. Use the BeginUpdate method to defer OnChanged events until an equal number of EndUpdate methods have been called.
Overloaded. Fills a path on the current TCanvas.
FillPath fills a TRSPathData, with the current Stroke or Pen.
If the path is empty, FillPath does nothing. In this case, FillPath does not raise any errors.
Translates and scales the current TRSPathData to fit a specified rectangle area.
Converts each curve in the current TRSPathData into a sequence of connected line segments.
The Flatness parameter specifies the maximum permitted error between the curve and its flattened approximation. By default, it is 0.25. Reducing the flatness value will increase the number of line segments in the approximation.
FlattenToPolygon(TRSPolygon,Single)
Converts the current TRSPathData into a sequence of connected line segments and returns the sequence as a TRSPolygon.
The Polygon parameter is the return variable. It is the result of the conversion.
Flatness is an optional parameter that specifies the maximum permitted error between the curve and its flattened approximation. By default, it is 0.25. Reducing the flatness value will increase the number of line segments in the approximation.
Returns the bounding rectangle of the current TRSPathData. When the path is drawn, the rectangle returned by GetBounds is not affected by the thickness and style of the pen stroke.
Returns the length of the path.
Note |
---|
It is recommended to Flatten the path before calling this method. |
Appends a line to the current TRSPathData.
The line is defined by the end point of the TRSPathData and a point that depends on the specified parameter.
HLineTo adds the specified point to the Points array. The end point of the line is moved horizontally from the last point of the TPathData to the point with the x-coordinate equal to X. The added point is of type ppLineTo.
To move the start point of the line, call MoveTo or MoveToRel before calling HLineTo.
To find the last point of the TRSPathData, call the LastPoint method.
Appends a line to the current TRSPathData.
The line is defined by the end point of the TRSPathData and a point that depends on the specified parameter.
HLineToRel adds the specified point to the Points array. The The end point of the line is moved horizontally by a distance equal to X to the end point of the TRSPathData. The added point is of type ppLineTo.
To move the start point of the line, call MoveTo or MoveToRel before calling HLineToRel.
To find the last point of the TRSPathData, call the LastPoint method.
Return true if there are no points in the path
Returns the end point of the current TRSPathData. LastPoint returns a TRSPoint.
Appends a line to the current TRSPathData.
The line is defined by the end point of the TRSPathData and a specified point.
To move the start point of the line, call MoveTo or MoveToRel before calling LineTo.
LineTo adds P to Points . The added point is of type ppLineTo.
To find the last point of the TRSPathData, call the LastPoint method.
Appends a line to the current TRSPathData.
The line is defined by the end point of the TPathData and a point that depends on the point specified by the parameter.
To move the start point of the line, call MoveTo or MoveToRel before calling LineToRel.
LineToRel adds P to Points . Its coordinates are equal to the sum between the coordinates of the last point and the coordinates of P. The added point is of type ppLineTo.
To find the last point of the TRSPathData, call the LastPoint method.
Adds a specified point to the end of the current TRSPathData.
Use MoveTo to customize the start point for a new element to be added to the current TRSPathData.
MoveTo adds the specified point to the Points array. The added point is of type ppMoveTo.
When a TRSPathData is drawn on a canvas, a MoveTo point and the previous point are not visibly connected (no line is drawn between them).
To find the last point of the TRSPathData, call the LastPoint method.
Adds a specified point to the end of the current TRSPathData.
Use MoveToRel to customize the start point for a new element to be added to the current TRSPathData.
MoveToRel adds the specified point to the Points array. Its coordinates are equal to the sum between the coordinates of the last point and the coordinates of P. The added point is of type ppMoveTo.
When a TRSPathData is drawn on a canvas, a MoveToRel point and the previous point are not visibly connected (no line is drawn between them).
To find the last point of the TRSPathData, call the LastPoint method.
Overloaded. Returns true if the point specified by X and Y is inside the path
Overloaded. Returns true if the specified point is inside the path
PointInPathOutline(Single,Single,Single)
Overloaded. Returns true if the point specified by X and Y is inside the path outline (i.e., the stroke of the path). The StrokeWidth specifies the width of the path outline.
PointInPathOutline(TRSPoint,Single)
Overloaded. Returns true if the specified point is inside the path outline (i.e., the stroke of the path). The StrokeWidth specifies the width of the path outline.
QuadCurveTo(TRSPoint,TRSPoint)
Appends a curve to the current TRSPathData.
The curve is defined by 4 points:
• A start point--the last point of the TPathData.
• Control point
• An end point, specified by the EndPoint parameter.
QuaveCurveTo adds the control points and the end point of the curve to the Points array. The added points are of type ppCurveTo.
To move the start point of the curve, call the MoveTo or MoveToRel method before calling QuadCurveTo.
To find the end point of the TRSPathData, call the LastPoint method.
Reads TRSPathData from the virtual property Path (created by DefineProperties) when streaming from the TStream Stream.
Scales the current TRSPathData.
SmoothCurveTo(TRSPoint,TRSPoint)
Appends a smooth curve to the current TRSPathData.
The smooth curve is defined by 4 points:
• A start point--the last point of the TPathData.
• Two control points. If Points has more than two items, the first control point coincides with the start point of the curve, otherwise it is equal to the second control point. The Control2 parameter specifies the second control point.
• An end point, specified by the EndPoint parameter.
SmoothCurveTo adds the control points and the end point of the curve to the Points array. The added points are of type ppCurveTo.
To move the start point of the curve, call the MoveTo or MoveToRel method before calling SmoothCurveTo.
To find the end point of the TRSPathData, call the LastPoint method.
SmoothCurveToRel(TRSPoint,TRSPoint)
Appends a smooth curve to the current TRSPathData.
The smooth curve is defined by 4 points that depend on the last point of the current TRSPathData.
The start point of the curve is the end point of the TRSPathData.
If Points has more than 2 items, the first control point coincides with the start point, otherwise it is equal to the second control point.
The ControlPoint2 parameter's coordinates specify the distances to the last point of the current TRSPathData, on each axis, for the second control point of the curve.
The EndPoint parameter's coordinates specify the distances to the last point of the current TRSPathData, on each axis, for the end point of the curve.
SmoothCurveToRel adds the control points and the end point of the curve to the Points array. The coordinates for each point are equal to the sum between the coordinates of the last point of the current TRSPathData and the coordinates of the corresponding points specified by the parameters. The added points are of type ppCurveTo.
To move the start point of the curve, call the MoveTo or MoveToRel method before calling SmoothCurveToRel.
To find the end point of the TRSPathData, call the LastPoint method.
SplitDataByLength(Integer,String)
Returns the string representation of the path data. The string representation is split every Len characters using the specified delimiter.
SplitDataByLength returns a string that can be multiple lines of no more than Len length.
Converts the path data into an array of polygons.
Note |
---|
It is recommended that Flatten is called before calling ToPolygons |
Translates the current TRSPathData.
Translate moves the current TRSPathData for a specified distance on each axis.
Appends a line to the current TRSPathData.
The line is defined by the end point of the TRSPathData and a point that depends on the specified parameter.
VLineTo adds the specified point to the Points array. The end point of the line is moved vertically from the last point of the TPathData to the point with the y-coordinate equal to Y. The added point is of type ppLineTo.
To move the start point of the line, call MoveTo or MoveToRel before calling VLineTo.
To find the last point of the TRSPathData, call the LastPoint method.
Appends a line to the current TRSPathData.
The line is defined by the end point of the TRSPathData and a point that depends on the specified parameter.
VLineToRel adds the specified point to the Points array. The The end point of the line is moved vertically by a distance equal to Y to the end point of the TRSPathData. The added point is of type ppLineTo.
To move the start point of the line, call MoveTo or MoveToRel before calling VLineToRel.
To find the last point of the TRSPathData, call the LastPoint method.
Writes TRSPathData to the virtual property Path (created by DefineProperties) when streaming to the TStream Stream.