copyWith method

ThemeData copyWith({
  1. Brightness? brightness,
  2. VisualDensity? visualDensity,
  3. Typography? typography,
  4. AccentColor? accentColor,
  5. Color? activeColor,
  6. Color? inactiveColor,
  7. Color? inactiveBackgroundColor,
  8. Color? disabledColor,
  9. Color? scaffoldBackgroundColor,
  10. Color? acrylicBackgroundColor,
  11. Color? shadowColor,
  12. Duration? fasterAnimationDuration,
  13. Duration? fastAnimationDuration,
  14. Duration? mediumAnimationDuration,
  15. Duration? slowAnimationDuration,
  16. Curve? animationCurve,
  17. ButtonState<MouseCursor>? inputMouseCursor,
  18. ButtonThemeData? buttonTheme,
  19. BottomNavigationThemeData? bottomNavigationTheme,
  20. BottomSheetThemeData? bottomSheetTheme,
  21. CheckboxThemeData? checkboxTheme,
  22. ChipThemeData? chipTheme,
  23. ToggleSwitchThemeData? toggleSwitchTheme,
  24. IconThemeData? iconTheme,
  25. SplitButtonThemeData? splitButtonTheme,
  26. ContentDialogThemeData? dialogTheme,
  27. TooltipThemeData? tooltipTheme,
  28. DividerThemeData? dividerTheme,
  29. NavigationPaneThemeData? navigationPaneTheme,
  30. RadioButtonThemeData? radioButtonTheme,
  31. ToggleButtonThemeData? toggleButtonTheme,
  32. SliderThemeData? sliderTheme,
  33. InfoBarThemeData? infoBarTheme,
  34. PillButtonBarThemeData? pillButtonBarTheme,
  35. FocusThemeData? focusTheme,
  36. ScrollbarThemeData? scrollbarTheme,
  37. SnackbarThemeData? snackbarTheme,
})

Implementation

ThemeData copyWith({
  Brightness? brightness,
  VisualDensity? visualDensity,
  Typography? typography,
  AccentColor? accentColor,
  Color? activeColor,
  Color? inactiveColor,
  Color? inactiveBackgroundColor,
  Color? disabledColor,
  Color? scaffoldBackgroundColor,
  Color? acrylicBackgroundColor,
  Color? shadowColor,
  Duration? fasterAnimationDuration,
  Duration? fastAnimationDuration,
  Duration? mediumAnimationDuration,
  Duration? slowAnimationDuration,
  Curve? animationCurve,
  ButtonState<MouseCursor>? inputMouseCursor,
  ButtonThemeData? buttonTheme,
  BottomNavigationThemeData? bottomNavigationTheme,
  BottomSheetThemeData? bottomSheetTheme,
  CheckboxThemeData? checkboxTheme,
  ChipThemeData? chipTheme,
  ToggleSwitchThemeData? toggleSwitchTheme,
  IconThemeData? iconTheme,
  SplitButtonThemeData? splitButtonTheme,
  ContentDialogThemeData? dialogTheme,
  TooltipThemeData? tooltipTheme,
  DividerThemeData? dividerTheme,
  NavigationPaneThemeData? navigationPaneTheme,
  RadioButtonThemeData? radioButtonTheme,
  ToggleButtonThemeData? toggleButtonTheme,
  SliderThemeData? sliderTheme,
  InfoBarThemeData? infoBarTheme,
  PillButtonBarThemeData? pillButtonBarTheme,
  FocusThemeData? focusTheme,
  ScrollbarThemeData? scrollbarTheme,
  SnackbarThemeData? snackbarTheme,
}) {
  return ThemeData.raw(
    brightness: brightness ?? this.brightness,
    visualDensity: visualDensity ?? this.visualDensity,
    typography: typography ?? this.typography,
    accentColor: accentColor ?? this.accentColor,
    activeColor: activeColor ?? this.activeColor,
    inactiveColor: inactiveColor ?? this.inactiveColor,
    shadowColor: shadowColor ?? this.shadowColor,
    inactiveBackgroundColor:
        inactiveBackgroundColor ?? this.inactiveBackgroundColor,
    disabledColor: disabledColor ?? this.disabledColor,
    scaffoldBackgroundColor:
        scaffoldBackgroundColor ?? this.scaffoldBackgroundColor,
    acrylicBackgroundColor:
        acrylicBackgroundColor ?? this.acrylicBackgroundColor,
    fasterAnimationDuration:
        fasterAnimationDuration ?? this.fasterAnimationDuration,
    fastAnimationDuration:
        fastAnimationDuration ?? this.fastAnimationDuration,
    mediumAnimationDuration:
        mediumAnimationDuration ?? this.mediumAnimationDuration,
    slowAnimationDuration:
        slowAnimationDuration ?? this.slowAnimationDuration,
    inputMouseCursor: inputMouseCursor ?? this.inputMouseCursor,
    animationCurve: animationCurve ?? this.animationCurve,
    buttonTheme: this.buttonTheme.merge(buttonTheme),
    bottomNavigationTheme:
        this.bottomNavigationTheme.merge(bottomNavigationTheme),
    bottomSheetTheme: this.bottomSheetTheme.merge(bottomSheetTheme),
    checkboxTheme: this.checkboxTheme.merge(checkboxTheme),
    chipTheme: this.chipTheme.merge(chipTheme),
    dialogTheme: this.dialogTheme.merge(dialogTheme),
    dividerTheme: this.dividerTheme.merge(dividerTheme),
    focusTheme: this.focusTheme.merge(focusTheme),
    iconTheme: this.iconTheme.merge(iconTheme),
    infoBarTheme: this.infoBarTheme.merge(infoBarTheme),
    pillButtonBarTheme: this.pillButtonBarTheme.merge(pillButtonBarTheme),
    navigationPaneTheme: this.navigationPaneTheme.merge(navigationPaneTheme),
    radioButtonTheme: this.radioButtonTheme.merge(radioButtonTheme),
    scrollbarTheme: this.scrollbarTheme.merge(scrollbarTheme),
    sliderTheme: this.sliderTheme.merge(sliderTheme),
    splitButtonTheme: this.splitButtonTheme.merge(splitButtonTheme),
    toggleButtonTheme: this.toggleButtonTheme.merge(toggleButtonTheme),
    toggleSwitchTheme: this.toggleSwitchTheme.merge(toggleSwitchTheme),
    tooltipTheme: this.tooltipTheme.merge(tooltipTheme),
    snackbarTheme: this.snackbarTheme.merge(snackbarTheme),
  );
}