pseong

플러터(Flutter) 앱바 배경색이 안 바뀔 때 본문

프론트엔드/플러터

플러터(Flutter) 앱바 배경색이 안 바뀔 때

pseong 2021. 12. 22. 13:25

설정 코드를 넣어도 자꾸 앱바 배경이 안 바뀌길래, primarySwatch를 설정하였더니 앱바 배경색이 바뀌었다.

ThemeData theme() {
  return ThemeData(
    primarySwatch: Colors.green,
    appBarTheme: const AppBarTheme(
      iconTheme: IconThemeData(color: Colors.white),
    ),
  );
}

primarySwatch: 배경색

Comments