실습 CODE
import 'package:flutter/material.dart';
class HomeScreen extends StatelessWidget {
const HomeScreen({Key? key}) : super(key: key);
@override
Widget build(BuildContext context) {
return Scaffold(
body: SafeArea(
bottom: false,
child: Container(
color: Colors.black,
child: Column(
mainAxisAlignment: MainAxisAlignment.spaceEvenly,
children: [
Row(
mainAxisAlignment: MainAxisAlignment.spaceAround,
children: [
Container(
height: 50.0,
width: 50.0,
color: Colors.red,
),
Container(
height: 50.0,
width: 50.0,
color: Colors.orange,
),
Container(
height: 50.0,
width: 50.0,
color: Colors.yellow,
),
Container(
height: 50.0,
width: 50.0,
color: Colors.green,
),
],
),
Container(
height: 50.0,
width: 50.0,
color: Colors.orange,
),
Row(
mainAxisAlignment: MainAxisAlignment.end,
children: [
Container(
height: 50.0,
width: 50.0,
color: Colors.red,
),
Container(
height: 50.0,
width: 50.0,
color: Colors.orange,
),
Container(
height: 50.0,
width: 50.0,
color: Colors.yellow,
),
Container(
height: 50.0,
width: 50.0,
color: Colors.green,
),
],
),
Container(
height: 50.0,
width: 50.0,
color: Colors.green,
),
],
),
),
),
);
}
}
'Flutter' 카테고리의 다른 글
[Flutter] StatefulWidget 이론 (0) | 2023.10.12 |
---|---|
[Flutter] HTTP 프로토콜 사용하기 / Webview 사용법 (4.X 기준) (1) | 2023.10.10 |
[Flutter] row and column (0) | 2023.09.22 |
[Flutter] Splash Screen (0) | 2023.09.22 |
[Dart] Dart 비동기 프로그래밍 (Async Programming) (0) | 2023.09.20 |