cShadow method
Widget
cShadow({
- BoxShape shape = BoxShape.rectangle,
- Clip clipBehavior = Clip.none,
- BorderRadius? borderRadius,
- double elevation = 0.0,
- Color color = Colors.transparent,
Add a shadow effect to the widget.
This extension allows you to add a shadow effect to a widget using PhysicalModel
.
shape
specifies the shape of the widget.
clipBehavior
specifies the clipping behavior.
borderRadius
specifies the border radius for rounded corners (optional).
elevation
specifies the shadow elevation.
color
specifies the color of the shadow.
Implementation
Widget cShadow({
BoxShape shape = BoxShape.rectangle,
Clip clipBehavior = Clip.none,
BorderRadius? borderRadius,
double elevation = 0.0,
Color color = Colors.transparent,
}) =>
PhysicalModel(
shape: shape,
clipBehavior: clipBehavior,
borderRadius: borderRadius,
elevation: elevation,
color: color,
child: this,
);