ClipPathLayer constructor

ClipPathLayer(
  1. {Path? clipPath,
  2. Clip clipBehavior = Clip.antiAlias}
)

Creates a layer with a path-based clip.

The clipPath and clipBehavior properties must be non-null before the compositing phase of the pipeline.

Implementation

ClipPathLayer({
  Path? clipPath,
  Clip clipBehavior = Clip.antiAlias,
}) : _clipPath = clipPath,
     _clipBehavior = clipBehavior,
     assert(clipBehavior != Clip.none);