ContainerModifier constructor
const
ContainerModifier({
- Key? key,
- Widget? child,
- Key? modifierKey,
- AlignmentGeometry? alignment,
- EdgeInsetsGeometry? padding,
- Color? color,
- Decoration? decoration,
- Decoration? foregroundDecoration,
- double? width,
- double? height,
- BoxConstraints? constraints,
- EdgeInsetsGeometry? margin,
- Matrix4? transform,
- AlignmentGeometry? transformAlignment,
- Clip clipBehavior = Clip.none,
Creates a widget that combines common painting, positioning, and sizing widgets.
The height and width values include the padding.
The color and decoration arguments cannot both be supplied, since
it would potentially result in the decoration drawing over the background
color. To supply a decoration with a color, use decoration: BoxDecoration(color: color).
Implementation
const ContainerModifier({
super.key,
super.child,
super.modifierKey,
this.alignment,
this.padding,
this.color,
this.decoration,
this.foregroundDecoration,
this.width,
this.height,
this.constraints,
this.margin,
this.transform,
this.transformAlignment,
this.clipBehavior = Clip.none,
});