AppBarTheme constructor

const AppBarTheme(
  1. {Color? color,
  2. Color? backgroundColor,
  3. Color? foregroundColor,
  4. double? elevation,
  5. double? scrolledUnderElevation,
  6. Color? shadowColor,
  7. Color? surfaceTintColor,
  8. ShapeBorder? shape,
  9. IconThemeData? iconTheme,
  10. IconThemeData? actionsIconTheme,
  11. bool? centerTitle,
  12. double? titleSpacing,
  13. double? toolbarHeight,
  14. TextStyle? toolbarTextStyle,
  15. TextStyle? titleTextStyle,
  16. SystemUiOverlayStyle? systemOverlayStyle}
)

Creates a theme that can be used for ThemeData.appBarTheme.

Implementation

const AppBarTheme({
  Color? color,
  Color? backgroundColor,
  this.foregroundColor,
  this.elevation,
  this.scrolledUnderElevation,
  this.shadowColor,
  this.surfaceTintColor,
  this.shape,
  this.iconTheme,
  this.actionsIconTheme,
  this.centerTitle,
  this.titleSpacing,
  this.toolbarHeight,
  this.toolbarTextStyle,
  this.titleTextStyle,
  this.systemOverlayStyle,
}) : assert(
       color == null || backgroundColor == null,
       'The color and backgroundColor parameters mean the same thing. Only specify one.',
     ),
     backgroundColor = backgroundColor ?? color;