전체 글(74)
-
ex14. Keypad
import 'package:flutter/material.dart';class ExKeypad extends StatelessWidget { const ExKeypad({super.key}); @override Widget build(BuildContext context) { return Scaffold( body: SafeArea( child: Column( children: [ Expanded( flex: 1, child: Container(), ), Expanded( flex: 2, child: Co..
2024.06.12 -
ex13. Banner 실습
import 'package:flutter/material.dart';class ExBanner extends StatelessWidget { const ExBanner({super.key}); @override Widget build(BuildContext context) { return Scaffold( body: SafeArea( child: Container( width: double.infinity, height: 90, margin: EdgeInsets.all(16), decoration: BoxDecoration( color: Colors.grey[200], ..
2024.06.12 -
ex12. Flexible과 Expanded
✅ Flexible vs Expandedimport 'package:flutter/material.dart';class ExFlexible extends StatelessWidget { const ExFlexible({super.key}); @override Widget build(BuildContext context) { return Scaffold( body: SafeArea( child: Column( children: [ // 1. Flexible과 Expanded를 사용하지 않았을 때! SizedBox(height: 20,), Text('Flexible, expanded 미사용'), ..
2024.06.12 -
ex11. SizedBox 실습
import 'package:flutter/material.dart';class EXKaKao extends StatelessWidget { const EXKaKao({Key? key}) : super(key: key); @override Widget build(BuildContext context) { return Scaffold( body: SafeArea( child: Container( width: double.infinity, height: 50, margin: EdgeInsets.all(10), decoration: BoxDecoration( color: Colors.yellow..
2024.06.12 -
ex10. SizedBox
✅ 배너✅ SizedBox✅ ExSizedBoximport 'package:flutter/material.dart';class ExSizedBox extends StatelessWidget { const ExSizedBox({super.key}); // sizedbox의 목적! // 1. child 위젯의 크기를 조정하기 위한 목적! // 2. 위젯들 사이의 공간을 추가하기 위한 목적! @override Widget build(BuildContext context) { return Scaffold( body: SafeArea( child: Column( children: [ Container( width:..
2024.06.12 -
ex09. Container 실습
import 'package:flutter/material.dart';class ExExample extends StatelessWidget { const ExExample({Key? key}); @override Widget build(BuildContext context) { return Scaffold( body: SafeArea( child: Center( child: Column( children: [ Center( child: Row( mainAxisAlignment: MainAxisAlignment.center, c..
2024.06.12