main.dart
import 'package:flutter/material.dart';
void main() {
runApp(
MaterialApp(
theme: ThemeData(primarySwatch: Colors.indigo),
home: Scaffold(
appBar: AppBar(
title: const Text("Flutter - Column Align Left")
),
body: bodyContent()
)
)
);
}
bodyContent(){
return Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Container(
color: Colors.green.shade200,
height: 50
),
Container(
color: Colors.blueGrey.shade200,
height: 50, width: 150
),
Container(
color: Colors.pink.shade200,
height: 50, width: 200
)
]
);
}
More flutter tutorials
- flutter – Column background color
- flutter – Column spacing
- flutter – Column full width
- flutter – Column center
- flutter – Column items equal height
- flutter – Column items stretch horizontally
- flutter – Column height wrap content
- flutter – Column align bottom
- flutter – Column align bottom right
- flutter – Column space evenly
- flutter – Column vertical direction
- flutter – Row space between
- flutter – Row height
- flutter – Row space around
- flutter – Row space evenly