MainAxisAlignment
        Inherits: Enum
How the children should be placed along the main axis.
Properties
- 
          CENTER–Place the children as close to the middle of the main axis as possible. 
- 
          END–Place the children as close to the end of the main axis as possible. 
- 
          SPACE_AROUND–Place the free space evenly between the children as well as half of that space 
- 
          SPACE_BETWEEN–Place the free space evenly between the children. 
- 
          SPACE_EVENLY–Place the free space evenly between the children as well as before and after the 
- 
          START–Place the children as close to the start of the main axis as possible. 
Properties#
CENTER = 'center'
  
      class-attribute
      instance-attribute
  
#
    Place the children as close to the middle of the main axis as possible.
END = 'end'
  
      class-attribute
      instance-attribute
  
#
    Place the children as close to the end of the main axis as possible.
SPACE_AROUND = 'spaceAround'
  
      class-attribute
      instance-attribute
  
#
    Place the free space evenly between the children as well as half of that space before and after the first and last child.
SPACE_BETWEEN = 'spaceBetween'
  
      class-attribute
      instance-attribute
  
#
    Place the free space evenly between the children.
SPACE_EVENLY = 'spaceEvenly'
  
      class-attribute
      instance-attribute
  
#
    Place the free space evenly between the children as well as before and after the first and last child.
START = 'start'
  
      class-attribute
      instance-attribute
  
#
    Place the children as close to the start of the main axis as possible.
Usage example#
import flet as ft
def main(page: ft.Page):
    def items(count):
        items = []
        for i in range(1, count + 1):
            items.append(
                ft.Container(
                    content=ft.Text(value=str(i)),
                    alignment=ft.alignment.center,
                    width=50,
                    height=50,
                    bgcolor=ft.Colors.AMBER_500,
                )
            )
        return items
    def column_with_alignment(align: ft.MainAxisAlignment):
        return ft.Column(
            [
                ft.Text(str(align), size=10),
                ft.Container(
                    content=ft.Column(items(3), alignment=align),
                    bgcolor=ft.Colors.AMBER_100,
                    height=400,
                ),
            ]
        )
    page.add(
        ft.Row(
            [
                column_with_alignment(ft.MainAxisAlignment.START),
                column_with_alignment(ft.MainAxisAlignment.CENTER),
                column_with_alignment(ft.MainAxisAlignment.END),
                column_with_alignment(ft.MainAxisAlignment.SPACE_BETWEEN),
                column_with_alignment(ft.MainAxisAlignment.SPACE_AROUND),
                column_with_alignment(ft.MainAxisAlignment.SPACE_EVENLY),
            ],
            spacing=30,
            alignment=ft.MainAxisAlignment.START,
        )
    )
ft.run(main)
