[]
Represents a complex shape that may be composed of arcs, curves, and lines.
public interface IPath : IDisposable
Gets a value indicating if the active figure contains one or more segments.
bool FigureHasSegments { get; }
Gets a value indicating if there is an active figure to update.
bool FigureStarted { get; }
Gets a value indicating if the path is closed for subsequent modifications.
bool IsClosed { get; }
Adds a single arc to the path geometry.
void AddArc(ArcSegment arcSegment)
arcSegment
ArcSegmentThe arc segment to add to the figure.
Creates a cubic Bezier curve between the current point and the specified end point.
void AddBezier(PointF p1, PointF p2, PointF endPoint)
p1
System.Drawing.PointFThe first control point for the Bezier segment.
p2
System.Drawing.PointFThe second control point for the Bezier segment.
endPoint
System.Drawing.PointFThe end point for the Bezier segment.
Creates a line segment between the current point and the specified end point and adds it to the geometry sink.
void AddLine(PointF pointTo)
pointTo
System.Drawing.PointFThe end point of the line to draw.
Creates a quadratic Bezier curve between the current point and the specified end point.
void AddQuadraticBezier(PointF p1, PointF endPoint)
p1
System.Drawing.PointFThe control point of the quadratic Bezier segment.
endPoint
System.Drawing.PointFThe end point of the quadratic Bezier segment.
Starts a new figure at the specified point.
void BeginFigure(PointF point)
point
System.Drawing.PointFThe point at which to begin the new figure.
Discards the active figure.
void CancelFigure()
Closes the path for modifications. The path cannot be modified after it is closed.
void Close()
Ends the current figure; optionally, closes it.
void EndFigure(FigureEnd figureEnd)
figureEnd
FigureEndA value that indicates whether the current figure is closed. If the figure is closed, a line is drawn between the current point and the start point specified by BeginFigure(PointF).
Returns a rectangle that bounds this IPath.
RectangleF GetBounds()
A System.Drawing.RectangleF that represents a rectangle that bounds this IPath.
Returns a rectangle that bounds this IPath when this path is transformed by the specified System.Numerics.Matrix3x2.
RectangleF GetBounds(Matrix3x2 worldTransform)
worldTransform
System.Numerics.Matrix3x2The transform to apply to this path before calculating its bounds.
A System.Drawing.RectangleF that represents a rectangle that bounds this IPath.
Specifies the method used to determine which points are inside the geometry described by this IPath and which points are outside.
void SetFillMode(FillMode fillMode)
fillMode
FillModeThe method used to determine whether a given point is part of the geometry.