Class ImmutablePen
Describes how a stroke is drawn.
public class ImmutablePen : IPen, IEquatable<IPen>
- Inheritance
-
ImmutablePen
- Implements
- Inherited Members
- Extension Methods
Constructors
ImmutablePen(IImmutableBrush?, double, ImmutableDashStyle?, PenLineCap, PenLineJoin, double)
Initializes a new instance of the Pen class.
public ImmutablePen(IImmutableBrush? brush, double thickness = 1, ImmutableDashStyle? dashStyle = null, PenLineCap lineCap = PenLineCap.Flat, PenLineJoin lineJoin = PenLineJoin.Miter, double miterLimit = 10)
Parameters
brush
IImmutableBrushThe brush used to draw.
thickness
doubleThe stroke thickness.
dashStyle
ImmutableDashStyleThe dash style.
lineCap
PenLineCapThe line cap.
lineJoin
PenLineJoinThe line join.
miterLimit
doubleThe miter limit.
ImmutablePen(uint, double, ImmutableDashStyle?, PenLineCap, PenLineJoin, double)
Initializes a new instance of the Pen class.
public ImmutablePen(uint color, double thickness = 1, ImmutableDashStyle? dashStyle = null, PenLineCap lineCap = PenLineCap.Flat, PenLineJoin lineJoin = PenLineJoin.Miter, double miterLimit = 10)
Parameters
color
uintThe stroke color.
thickness
doubleThe stroke thickness.
dashStyle
ImmutableDashStyleThe dash style.
lineCap
PenLineCapSpecifies the type of graphic shape to use on both ends of a line.
lineJoin
PenLineJoinThe line join.
miterLimit
doubleThe miter limit.
Properties
Brush
Gets the brush used to draw the stroke.
public IBrush? Brush { get; }
Property Value
DashStyle
Specifies the style of dashed lines drawn with a Pen object.
public IDashStyle? DashStyle { get; }
Property Value
LineCap
Specifies the type of graphic shape to use on both ends of a line.
public PenLineCap LineCap { get; }
Property Value
LineJoin
Specifies how to join consecutive line or curve segments in a PathFigure (subpaths) contained in a PathGeometry object.
public PenLineJoin LineJoin { get; }
Property Value
MiterLimit
The limit on the ratio of the miter length to half this pen's Thickness.
public double MiterLimit { get; }
Property Value
Thickness
Gets the stroke thickness.
public double Thickness { get; }
Property Value
Methods
Equals(IPen?)
public bool Equals(IPen? other)
Parameters
other
IPen
Returns
Equals(object?)
public override bool Equals(object? obj)
Parameters
obj
object
Returns
GetHashCode()
public override int GetHashCode()