NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

GraphicsPath Class

Represents a series of connected lines and curves.

Object
   MarshalByRefObject
      GraphicsPath

[Visual Basic]
NotInheritable Public Class GraphicsPath
   Inherits MarshalByRefObject
   Implements ICloneable
[C#]
public sealed class GraphicsPath : MarshalByRefObject, ICloneable
[C++]
public __gc __sealed class GraphicsPath : public
   MarshalByRefObject, ICloneable
[JScript]
public class GraphicsPath extends MarshalByRefObject, ICloneable

Remarks

Applications use paths to draw outlines of shapes, fill the interiors of shapes, and create clipping regions. The graphics engine maintains the coordinates of geometric shapes in a path in world coordinate space. The coordinates are transformed by the current transform to the physical coordinate space when the path is used. As a result, an application can use a path multiple times. A path may be composed of any number of figures. Each figure is either composed of a sequence of connected lines and curves or a geometric shape primitive. The starting point of a figure is the first point in the sequence of connected lines and curves. The ending point is the last point in the sequence. The starting and ending points of a geometric shape primitive are defined by the primitive specification. A figure that consists of a sequence of connected lines and curves (whose starting and ending points may be coincident) is an open figure, unless it is closed explicitly. An open figure does not have an interior, and will be ignored when a path is filled or converted to clipping regions. The closeFigure method closes the current figure by connecting a line from the ending point to the starting point. A figure that consists of a geometric shape primitive is a closed figure. A new figure is implicitly started when a path is created, when a figure is closed, or explicitly when the startFigure method is called. When a geometric shape primitive is added to a path, it adds a figure containing the geometric shape, and also implicitly starts a new figure. Consequently, there is always a current figure in a path. When lines and curves are added to a path, an implicit line is added as needed to connect the ending point of the current figure to the starting point of the new lines and curves to form a sequence of connected lines and curves. A figure has a direction that describes how line and curve segments are traced between the starting point and the ending point. The direction is defined in the order that lines and curves are added to a figure, or is defined by the geometric shape primitive. The direction is used in determining the path interiors for clipping and fill.

Requirements

Namespace: System.Drawing.Drawing2D

Assembly: System.Drawing.dll

See Also

GraphicsPath Members | System.Drawing.Drawing2D Namespace