PdfLineCap enum Null safety

Specifies the line cap style to be used at the ends of the lines.

//Create a new PDF document.
PdfDocument document = PdfDocument()
  ..pages.add().graphics.drawRectangle(
      pen: PdfPen(PdfColor(255, 0, 0),
          dashStyle: PdfDashStyle.custom, lineCap: PdfLineCap.round)
        ..dashPattern = [4, 2, 1, 3],
      bounds: Rect.fromLTWH(0, 0, 200, 100));
//Save the document.
List<int> bytes = document.save();
//Close the document.
document.dispose();

Constants

flat → const PdfLineCap

The stroke is squared off at the endpoint of the path. There is no projection beyond the end of the path.

const PdfLineCap(0)
round → const PdfLineCap

A semicircular arc with a diameter equal to the line width is drawn around the endpoint and filled in.

const PdfLineCap(1)
square → const PdfLineCap

The stroke continues beyond the endpoint of the path for a distance equal to half the line width and is squared off.

const PdfLineCap(2)
values → const List<PdfLineCap>

A constant List of the values in this enum, in order of their declaration.

const List<PdfLineCap>

Properties

hashCode int
The hash code for this object. [...]
read-only, inherited
index int

The integer index of this enum.

final
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
toString() String
A string representation of this object. [...]
override

Operators

operator ==(Object other) bool
The equality operator. [...]
inherited