drawPath method

Graphics drawPath(
  1. Path path, [
  2. double x = 0,
  3. double y = 0,
  4. GMatrix? transform,
])

Appends a native path to the current drawing path, as x and y can offset the target position, while transform can be used to rotated, scale, translate, the given shape.

The method returns this, which allows for method chaining.

Implementation

Graphics drawPath(
  Path path, [
  double x = 0,
  double y = 0,
  GMatrix? transform,
]) {
  _path!.addPath(
    path,
    Offset(x, y),
    matrix4: transform?.toNative().storage,
  );
  return this;
}