mainAxisAlignment property
MainAxisAlignment
get
mainAxisAlignment
How the children should be placed along the main axis.
If the direction is Axis.horizontal, and the mainAxisAlignment is either MainAxisAlignment.start or MainAxisAlignment.end, then the textDirection must not be null.
If the direction is Axis.vertical, and the mainAxisAlignment is either MainAxisAlignment.start or MainAxisAlignment.end, then the verticalDirection must not be null.
Implementation
MainAxisAlignment get mainAxisAlignment => _mainAxisAlignment;
set
mainAxisAlignment
(MainAxisAlignment value)
Implementation
set mainAxisAlignment(MainAxisAlignment value) {
assert(value != MainAxisAlignment.spaceAround);
assert(value != MainAxisAlignment.spaceBetween);
assert(value != MainAxisAlignment.spaceEvenly);
if (_mainAxisAlignment != value) {
_mainAxisAlignment = value;
markNeedsLayout();
}
}