FlatButton은 2.0버전 이후로 사라지고 TextButton으로 사용해야 한다.
style 사용방식이 조금 달라져서 나중에 참고하고자 정리한다.
TextButton(
onPressed: () {},
child: Text(
'Text Button',
),
style: TextButton.styleFrom(
primary: Colors.red,
backgroundColor: Colors.yellow,
textStyle: TextStyle(fontSize: 10, fontStyle: FontStyle.italic)),
)
'App > Flutter' 카테고리의 다른 글
[Flutter] StatelessWidget / StatefulWidget 차이 (0) | 2021.10.08 |
---|---|
[Flutter] 윈도우에 플러터 설치하기 (0) | 2021.09.28 |