Wrap constructor

Wrap(
  1. {Key key,
  2. Axis direction: Axis.horizontal,
  3. WrapAlignment alignment: WrapAlignment.start,
  4. double spacing: 0.0,
  5. WrapAlignment runAlignment: WrapAlignment.start,
  6. double runSpacing: 0.0,
  7. WrapCrossAlignment crossAxisAlignment: WrapCrossAlignment.start,
  8. TextDirection textDirection,
  9. VerticalDirection verticalDirection: VerticalDirection.down,
  10. List<Widget> children: const []}
)

Creates a wrap layout.

By default, the wrap layout is horizontal and both the children and the runs are aligned to the start.

The textDirection argument defaults to the ambient Directionality, if any. If there is no ambient directionality, and a text direction is going to be necessary to decide which direction to lay the children in or to disambiguate start or end values for the main or cross axis directions, the textDirection must not be null.

Implementation

Wrap({
  Key key,
  this.direction = Axis.horizontal,
  this.alignment = WrapAlignment.start,
  this.spacing = 0.0,
  this.runAlignment = WrapAlignment.start,
  this.runSpacing = 0.0,
  this.crossAxisAlignment = WrapCrossAlignment.start,
  this.textDirection,
  this.verticalDirection = VerticalDirection.down,
  List<Widget> children = const <Widget>[],
}) : super(key: key, children: children);