ConstraintsTransformBox constructor Null safety
- {Key? key,
- Widget? child,
- TextDirection? textDirection,
- AlignmentGeometry alignment = Alignment.center,
- required BoxConstraintsTransform constraintsTransform,
- Clip clipBehavior = Clip.none,
- String debugTransformType = ''}
Creates a widget that uses a function to transform the constraints it passes to its child. If the child overflows the parent's constraints, a warning will be given in debug mode.
The debugTransformType
argument adds a debug label to this widget.
The alignment
, clipBehavior
and constraintsTransform
arguments must
not be null.
Implementation
const ConstraintsTransformBox({
super.key,
super.child,
this.textDirection,
this.alignment = Alignment.center,
required this.constraintsTransform,
this.clipBehavior = Clip.none,
String debugTransformType = '',
}) : _debugTransformLabel = debugTransformType,
assert(alignment != null),
assert(clipBehavior != null),
assert(constraintsTransform != null),
assert(debugTransformType != null);