AdaptiveContainerBuilder constructor

AdaptiveContainerBuilder({
  1. Key? key,
  2. AlignmentGeometry? alignment,
  3. EdgeInsetsGeometry? padding,
  4. Color? color,
  5. Decoration? decoration,
  6. Decoration? foregroundDecoration,
  7. EdgeInsetsGeometry? margin,
  8. Matrix4? transform,
  9. double? height,
  10. Clip clipBehavior = Clip.none,
  11. required AdaptiveWidgetBuilder builder,
})

Creates a widget that combines common painting, positioning, and sizing widgets.

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

AdaptiveContainerBuilder({
  Key? key,
  this.alignment,
  this.padding,
  this.color,
  this.decoration,
  this.foregroundDecoration,
  this.margin,
  this.transform,
  this.height,
  this.clipBehavior = Clip.none,
  required this.builder,
})  : assert(margin == null || margin.isNonNegative),
      assert(padding == null || padding.isNonNegative),
      assert(decoration == null || decoration.debugAssertIsValid()),
      assert(
          color == null || decoration == null,
          'Cannot provide both a color and a decoration\n'
          'To provide both, use "decoration: BoxDecoration(color: color)".'),
      super(key: key);