Show/Hide Toolbars

RiverSoftAVG Products Help

A TRSGPPath object stores a sequence of lines, curves, and shapes. You can draw the entire sequence by calling the TRSGPCanvas.DrawPath method. You can partition the sequence of lines, curves, and shapes into figures, and you can draw selected figures. You can also place markers in the sequence, so that you can draw selected portions of the path.

Namespace: RSGdiPlusGraphics

published property

FillMode

Specifies how to fill areas when the path intersects itself.

public property

Handle

Handle of the graphics object, used by the MS GDI+ flat API routines (Inherited from RSGdiPlusGraphics.TRSGPGraphicsObject.)

protected property

IsModified

Represents property IsModified.

public property

OnChange

Occurs when the graphics object changes.

noteNote

There are two events that are exactly the same, OnChanged and OnChange. The extra event name is to allow easier transition from other Delphi libraries, either the VCL (OnChanged) or FMX (OnChange) libraries. Use either one as needed. Only one event is triggered.

public property

OnChanged

Occurs when the graphics object changes.

noteNote

There are two events that are exactly the same, OnChanged and OnChange. The extra event name is to allow easier transition from other Delphi libraries, either the VCL (OnChanged) or FMX (OnChange) libraries. Use either one as needed. Only one event is triggered.

public property

Owner

Canvas that owns the object. The Canvas will free this graphics object if it is destroyed. However, to keep memory use under control, it is recommended that you free graphics objects when you are finished with them. (Inherited from RSGdiPlusGraphics.TRSGPGraphicsObject.)

public property

Points[Integer]

Specifies the points from the current path and theirs types.

Points gets the point and its type, specified by the index in the array of points of the path. Use Points to access the internal array of TRSGPPathPoint of the path.

AIndex specifies an index in the points array of the path.
 
 

protected property

UpdateCount

Represents property UpdateCount.

Top

CurveToRel adds the two control points and the end point of the curve to the Points array. The added point is of type CurveTo. To move the start point of the line, call   MoveTo or   MoveToRel before calling SmoothCurveTo.

To find the end point of the path, call the   LastPoint method.
 

public method

EndUpdate

Marks the end of an update session of the element and its children.
 
The update session must be started first by calling BeginUpdate.
 
EndUpdate decreases a updating semaphore. If all update sessions end and the semaphore is 0, EndUpdate signals a OnChange event.
 

public method

FitToRect(TRectF)

Translates and scales the current path to fit a specified rectangle area. The ARect parameter specifies the rectangle area to fit the path in.
 
 

public method

Flatten(Single)

Converts each curve in the current TPathData 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.
 

public method

GetBounds

Returns the bounding rectangle of the current path. When the path is drawn, the rectangle returned by GetBounds is not affected by the thickness and style of the pen stroke.

public method

GetEnumerator

Returns a RSGdiPlusGraphicsTypes.TRSGPPathPoint enumerator.
 
GetEnumerator returns a TPathPointEnumerator reference, which enumerates the path points contained within the path.
 
To process all these path points, call the TPathPointEnumerator GetCurrent method within a While MoveNext do loop.
 
 

protected method

GetHandle

Call this method to acquire a handle from the GDI+ flat API library (Overrides RSGdiPlusGraphics.TRSGPGraphicsObject.GetHandle.)

public method

GetPathData

Returns the record containing the path data (points and kinds)

public method

HLineTo(Single)

Appends a line to the current path.

The line is defined by the end point of the path and a point that depends on the specified parameter. The X parameter specifies the x-coordinate of the end point of the line. HLineTo adds the end point of the line to the     Points array. The end point of the line is moved horizontally from the last point of the path to the point with the x-coordinate equal to X. The added point is of type LineTo. To move the start point of the line, call     MoveTo or     MoveToRel before calling HLineTo.

To find the end point of the path, call the     LastPoint method.
 

public method

HLineToRel(Single)

Appends a line to the current path.

The line is defined by the end point of the path and a point that depends on the specified parameter. The X parameter specifies the distance to the end point of the current path on the x-axis. HLineToRel adds the end point of the line to the     Points array. The end point of the line is moved horizontally by a distance equal to X to the end point of the path. The added point is of type LineTo. To move the start point of the line, call     MoveTo or     MoveToRel before calling HLineToRel.

To find the end point of the path, call the     LastPoint method.
 

public method

IsOutlineVisiblePathPoint(Single,Single)

Overloaded.  Determines whether a specified point touches the outline of this path when the path is drawn by the owner canvas.

This method determines whether the test point touches the path outline that would be drawn by the owner canvas.pen. More points will touch an outline drawn by a wide pen than will touch an outline drawn by a narrow pen. The test is done in device coordinates.

public method

IsOutlineVisiblePathPoint(Single,Single,TRSGPPen,TRSGPCanvas)

Overloaded.  Determines whether a specified point touches the outline of this path when the path is drawn by a specified canvas and a specified pen.

This method determines whether the test point touches the path outline that would be drawn by the pen. More points will touch an outline drawn by a wide pen than will touch an outline drawn by a narrow pen. The aCanvas parameter specifies a world-to-device transformation. If the value of this parameter is nil, the test is done in world coordinates; otherwise, the test is done in device coordinates.

public method

IsOutlineVisiblePathPoint(TPointF)

Overloaded.  Determines whether a specified point touches the outline of this path when the path is drawn by the owner canvas.

This method determines whether the test point touches the path outline that would be drawn by the owner canvas.pen. More points will touch an outline drawn by a wide pen than will touch an outline drawn by a narrow pen. The test is done in device coordinates.

public method

IsOutlineVisiblePathPoint(TPointF,TRSGPPen,TRSGPCanvas)

Overloaded.  Determines whether a specified point touches the outline of this path when the path is drawn by a specified canvas and a specified pen.

This method determines whether the test point touches the path outline that would be drawn by the pen. More points will touch an outline drawn by a wide pen than will touch an outline drawn by a narrow pen. The aCanvas parameter specifies a world-to-device transformation. If the value of this parameter is nil, the test is done in world coordinates; otherwise, the test is done in device coordinates.

public method

IsVisiblePathPoint(Single,Single)

Overloaded.  Determines whether a specified point lies in the area that is filled when this path is filled by the Owner Canvas.

The test is performed in device coordinates.

public method

IsVisiblePathPoint(Single,Single,TRSGPCanvas)

Overloaded.  Determines whether a specified point lies in the area that is filled when this path is filled by the aCanvas parameter.

The aCanvas parameter specifies a world-to-device transformation. If the value of this parameter is nil, the test is done in world coordinates; otherwise, the test is done in device coordinates.

public method

IsVisiblePathPoint(TPointF)

Overloaded.  Determines whether a specified point lies in the area that is filled when this path is filled by the Owner Canvas.

The test is performed in device coordinates.

public method

IsVisiblePathPoint(TPointF,TRSGPCanvas)

Overloaded.  Determines whether a specified point lies in the area that is filled when this path is filled by the aCanvas parameter.

The aCanvas parameter specifies a world-to-device transformation. If the value of this parameter is nil, the test is done in world coordinates; otherwise, the test is done in device coordinates.

public method

Kinds

Returns an object for generating enumerators for the TRSGPPathPointKinds in the path

public method

LastPoint

Gets the ending point of the last figure in this path.

public method

LineTo(Single,Single)

Overloaded.  Appends a line to the current path.

The line is defined by the end point of the path and a specified point. The x1, y1 parameters specify the end point of the line to be added. 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 LineTo.

To find the end point of the path, call the     LastPoint method.
 

public method

LineTo(TPointF)

Overloaded.  Appends a line to the current path.

The line is defined by the end point of the path and a specified point. The P parameter specifies the end point of the line to be added. 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 LineTo.

To find the end point of the path, call the     LastPoint method.
 

public method

LineToRel(TPointF)

Appends a line to the current path.

The line is defined by the end point of the path and a point that depends on the point specified by the parameter. The P parameter's coordinates specify the distances to the last point of the current path, on each axis. LineToRel adds the end point of the line 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 LineTo. To move the start point of the line, call     MoveTo or     MoveToRel before calling LineToRel.

To find the end point of the path, call the     LastPoint method.
 

public method

Modified

Call this method to force the TRSGPPath object to reload the path from GDI+

public method

MoveTo(Single,Single)

Overloaded.  Adds a specified point to the end of the current path.

Use MoveTo to customize the start point for a new element to be added to the current path.

The x1, y1 parameters specify the coordinates of the point to be added. MoveTo adds the specified point to a Points array. The added point is of type MoveTo.
 
When a path 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 path, call the     LastPoint method.
 

public method

MoveTo(TPointF)

Overloaded.  Adds a specified point to the end of the current path.

Use MoveTo to customize the start point for a new element to be added to the current path.

The P parameter specifies the TPointF to be added. MoveTo adds the specified point to a Points array. The added point is of type MoveTo.
 
When a path 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 path, call the     LastPoint method.
 

public method

MoveToRel(TPointF)

Appends a specified TpointF to the current path.

MoveToRel customizes the start point for new elements to be added to the current path.

The P parameter's coordinates specify the distances to the end point of the current path, on each axis. MoveToRel adds a new 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 MoveTo.
 
The added point is the new start point of the element to be added to the path. When a path 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 path, call the     LastPoint method.
 
 

protected method

Notification(TRSGPCanvas)

Called when the Canvas is releasing control of the graphics object. The canvas will no longer be responsible for freeing the graphics object. (Inherited from RSGdiPlusGraphics.TRSGPGraphicsObject.)

public method

Outline(Single)

Flattens the path and then converts the path's data points so that they represent only the outline of the path.

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.

public method

Prepare(TRectF,Single)

Prepare the graphics object for drawing. Graphics objects respond in this method to upcoming calls. For example, gradient brushes can make sure the gradient will cover the entire rectangle. (Inherited from RSGdiPlusGraphics.TRSGPGraphicsObject.)

public method

QueryInterface(TGUID,Void)

Represents method QueryInterface(TGUID,Void). (Inherited from RSGdiPlusGraphics.TRSGPGraphicsObject.)

protected method

ReleaseHandle

Releases the underlying GDI+ object back to the GDI+ library. (Overrides RSGdiPlusGraphics.TRSGPGraphicsObject.ReleaseHandle.)

protected method

Reload

Represents method Reload.

public method

Reverse

Reverses the order of the points that define this path's lines and curves.

public method

Scale(Single,Single)

Scales the current path by the delta in X and Y. If dx, dy are > 1, the path gets bigger.

public method

SetPathData(TRSGPPathData)

Sets the path to use the path data (points and kinds)

public method

SmoothCurveTo(TPointF,TPointF)

Appends a smooth curve to the current path.

The smooth curve is defined by 4 points:
 

A start point--the last point of the path.

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 point is of type CurveTo. To move the start point of the line, call   MoveTo or   MoveToRel before calling SmoothCurveTo.

To find the end point of the path, call the   LastPoint method.
 

public method

SmoothCurveToRel(TPointF,TPointF)

Appends a smooth curve to the current path.

The smooth curve is defined by 4 points that depend on the last point of the current:
 

A start point--the last point of the path.

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 path, 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 path, 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 added point is of type CurveTo. The coordinates for each point are equal to the sum between the coordinates of the last point of the current path and the coordinates of the corresponding points specified by the parameters. To move the start point of the line, call   MoveTo or   MoveToRel before calling SmoothCurveToRel.

To find the end point of the path, call the   LastPoint method.
 

public method

StartPath

Starts a new figure without closing the current figure. Subsequent points added to this path are added to the new figure.

public method

Translate(Single,Single)

Translates the current path by the delta in X and Y. dX and dY are in path units.

public method

Update

Update native graphics object (Inherited from RSGdiPlusGraphics.TRSGPGraphicsObject.)

public method

Values

Returns an object for generating enumerators for the points in the path

public method

VLineTo(Single)

Appends a line to the current path.

The line is defined by the end point of the path and a point that depends on the specified parameter. The Y parameter specifies the y-coordinate of the end point of the line. VLineTo adds the end point of the line to the     Points array. The end point of the line is moved vertically from the last point of the path to the point with the Y-coordinate equal to Y. The added point is of type LineTo. To move the start point of the line, call     MoveTo or     MoveToRel before calling VLineTo. The added point is of type LineTo.

To find the end point of the path, call the     LastPoint method.
 

public method

VLineToRel(Single)

Appends a line to the current path.

The line is defined by the end point of the path and a point that depends on the specified parameter. The Y parameter specifies the distance to the end point of the current path on the y-axis. VLineToRel adds the end point of the line to the     Points array. The end point of the line is moved vertically by a distance equal to Y to the end point of the path. The added point is of type LineTo. To move the start point of the line, call     MoveTo or     MoveToRel before calling VLineToRel.

To find the end point of the path, call the     LastPoint method.
 

public method

Widen(Single)

Replaces this path with curves that enclose the area that is filled when this path is drawn by the owner canvas' pen. The Widen method also flattens the path.

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.

public method

_AddRef

Represents method _AddRef. (Inherited from RSGdiPlusGraphics.TRSGPGraphicsObject.)

public method

_Release

Represents method _Release. (Inherited from RSGdiPlusGraphics.TRSGPGraphicsObject.)

Top

RiverSoftAVG Products Help © 1996-2016 Thomas G. Grubb