PdfPath constructor

PdfPath({
  1. PdfPen? pen,
  2. PdfBrush? brush,
  3. PdfFillMode fillMode = PdfFillMode.winding,
  4. List<Offset> points = const <Offset>[],
  5. List<int>? pathTypes,
})

Initializes a new instance of the PdfPath class with pen, brush, fillMode, points and pathTypes

Implementation

PdfPath(
    {PdfPen? pen,
    PdfBrush? brush,
    PdfFillMode fillMode = PdfFillMode.winding,
    List<Offset> points = const <Offset>[],
    List<int>? pathTypes}) {
  _helper = PdfPathHelper(this);
  if (pen != null) {
    super.pen = pen;
  }
  if (points.isNotEmpty && pathTypes != null) {
    addPath(points, pathTypes);
  }
  _helper.fillMode = fillMode;
  this.brush = brush;
}