ClipPathWidgetExtensions extension

Extension methods for Widget that provide convenient path clipping functionality.

This extension adds a method to easily apply custom path clipping to any widget using ClipPath. This allows for creating complex, custom-shaped clipping regions beyond the standard rectangular and oval shapes.

Path clipping is useful for creating unique visual effects, custom shapes, and complex masking operations on widgets.

Example usage:

Container(color: Colors.blue)
  .clipPath(
    clipper: MyCustomClipper(),
    clipBehavior: Clip.antiAlias,
  );
on

Methods

clipPath({CustomClipper<Path>? clipper, Clip clipBehavior = Clip.antiAlias}) ClipPath

Available on Widget, provided by the ClipPathWidgetExtensions extension

Clips the widget using a custom path.