copyWith method
FlexColorScheme
copyWith({
- ColorScheme? colorScheme,
- Brightness? brightness,
- Color? primary,
- Color? primaryVariant,
- Color? secondary,
- Color? secondaryVariant,
- Color? surface,
- Color? background,
- Color? error,
- Color? scaffoldBackground,
- Color? dialogBackground,
- Color? appBarBackground,
- Color? onPrimary,
- Color? onSecondary,
- Color? onSurface,
- Color? onBackground,
- Color? onError,
- FlexTabBarStyle? tabBarStyle,
- double? appBarElevation,
- double? bottomAppBarElevation,
- bool? tooltipsMatchBackground,
- bool? transparentStatusBar,
- VisualDensity? visualDensity,
- TextTheme? textTheme,
- TextTheme? primaryTextTheme,
- String? fontFamily,
- TargetPlatform? platform,
- Typography? typography,
- bool? applyElevationOverlayColor,
- bool? useSubThemes,
- FlexSubThemesData? subThemesData,
Copy the object with one or more provided properties changed.
Implementation
FlexColorScheme copyWith({
ColorScheme? colorScheme,
Brightness? brightness,
Color? primary,
Color? primaryVariant,
Color? secondary,
Color? secondaryVariant,
Color? surface,
Color? background,
Color? error,
Color? scaffoldBackground,
Color? dialogBackground,
Color? appBarBackground,
Color? onPrimary,
Color? onSecondary,
Color? onSurface,
Color? onBackground,
Color? onError,
FlexTabBarStyle? tabBarStyle,
double? appBarElevation,
double? bottomAppBarElevation,
bool? tooltipsMatchBackground,
bool? transparentStatusBar,
VisualDensity? visualDensity,
TextTheme? textTheme,
TextTheme? primaryTextTheme,
String? fontFamily,
TargetPlatform? platform,
Typography? typography,
bool? applyElevationOverlayColor,
bool? useSubThemes,
FlexSubThemesData? subThemesData,
}) {
return FlexColorScheme(
colorScheme: colorScheme ?? this.colorScheme,
brightness: brightness ?? this.brightness,
primary: primary ?? this.primary,
primaryVariant: primaryVariant ?? this.primaryVariant,
secondary: secondary ?? this.secondary,
secondaryVariant: secondaryVariant ?? this.secondaryVariant,
surface: surface ?? this.surface,
background: background ?? this.background,
error: error ?? this.error,
scaffoldBackground: scaffoldBackground ?? this.scaffoldBackground,
appBarBackground: appBarBackground ?? this.appBarBackground,
dialogBackground: dialogBackground ?? this.dialogBackground,
onPrimary: onPrimary ?? this.onPrimary,
onSecondary: onSecondary ?? this.onSecondary,
onSurface: onSurface ?? this.onSurface,
onBackground: onBackground ?? this.onBackground,
onError: onError ?? this.onError,
tabBarStyle: tabBarStyle ?? this.tabBarStyle,
appBarElevation: appBarElevation ?? this.appBarElevation,
bottomAppBarElevation:
bottomAppBarElevation ?? this.bottomAppBarElevation,
tooltipsMatchBackground:
tooltipsMatchBackground ?? this.tooltipsMatchBackground,
transparentStatusBar: transparentStatusBar ?? this.transparentStatusBar,
visualDensity: visualDensity ?? this.visualDensity,
textTheme: textTheme ?? this.textTheme,
primaryTextTheme: primaryTextTheme ?? this.primaryTextTheme,
fontFamily: fontFamily ?? this.fontFamily,
platform: platform ?? this.platform,
typography: typography ?? this.typography,
applyElevationOverlayColor:
applyElevationOverlayColor ?? this.applyElevationOverlayColor,
useSubThemes: useSubThemes ?? this.useSubThemes,
subThemesData: subThemesData ?? this.subThemesData,
);
}