PdfPen class
Namespace: PdfNetStack.Drawing
Assembly: PdfNetStack.dll
Package: PdfNetStack
How lines and outlines are stroked. Immutable; use with to derive variants.
public sealed record PdfPen : IEquatable<PdfPen>Inheritance
Implements
Constructors
Section titled “Constructors”PdfPen(PdfColor, double)
Section titled “ PdfPen(PdfColor, double)”Creates a solid pen.
public PdfPen(PdfColor color, double width = 1)Parameters
Section titled “Parameters”color PdfColor
Stroke color.
width double
Line width in points. 0 draws the thinnest line the device can show.
Properties
Section titled “Properties”A 1 point black pen.
public static PdfPen Black { get; }Property Value
Section titled “Property Value”Stroke color.
public PdfColor Color { get; init; }Property Value
Section titled “Property Value”DashOffset
Section titled “ DashOffset”Offset into the dash pattern where the line starts.
public double DashOffset { get; init; }Property Value
Section titled “Property Value”DashPattern
Section titled “ DashPattern”Alternating dash and gap lengths in points; empty for a solid line.
public IReadOnlyList<double> DashPattern { get; init; }Property Value
Section titled “Property Value”LineCap
Section titled “ LineCap”End shape. Default butt.
public PdfLineCap LineCap { get; init; }Property Value
Section titled “Property Value”LineJoin
Section titled “ LineJoin”Corner shape. Default miter.
public PdfLineJoin LineJoin { get; init; }Property Value
Section titled “Property Value”MiterLimit
Section titled “ MiterLimit”Miter limit, at least 1. Default 10, as in PDF.
public double MiterLimit { get; init; }Property Value
Section titled “Property Value”Line width in points.
public double Width { get; init; }