Flex class abstract

Base class for widgets that arrange children in a one-dimensional array.

See also:

  • Row, for a horizontal layout.
  • Column, for a vertical layout.
Inheritance
Implementers

Constructors

Flex({required Axis direction, Key? key, MainAxisAlignment mainAxisAlignment = MainAxisAlignment.start, MainAxisSize mainAxisSize = MainAxisSize.max, CrossAxisAlignment crossAxisAlignment = CrossAxisAlignment.center, List<Widget> children = const <Widget>[], int spacing = 0})
Creates a flex layout widget.
const

Properties

children List<Widget>
The widgets below this widget in the tree
finalinherited
crossAxisAlignment CrossAxisAlignment
How the children should be placed along the cross axis.
final
direction Axis
The direction to use as the main axis.
final
hashCode int
The hash code for this object.
no setterinherited
key Key?
Controls how this widget replaces another of the same type.
finalinherited
mainAxisAlignment MainAxisAlignment
How the children should be placed along the main axis.
final
mainAxisSize MainAxisSize
How much space should be occupied in the main axis.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
spacing int
The amount of space to place between children in the main axis.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited