cutoutBuilder property

void Function(Path path, Rect bounds) cutoutBuilder
final

An optional callback that customizes the cutout shape.

Defaults to FModalBarrier.defaultCutoutBuilder which adds a plain rectangle matching the cutout's bounds.

To add a circular cutout:

cutoutBuilder: (path, bounds) => path.addOval(bounds.deflate(3)),

Implementation

final void Function(Path path, Rect bounds) cutoutBuilder;