copyWith method

NavigationRailThemeData copyWith(
  1. {Color? backgroundColor,
  2. double? elevation,
  3. TextStyle? unselectedLabelTextStyle,
  4. TextStyle? selectedLabelTextStyle,
  5. IconThemeData? unselectedIconTheme,
  6. IconThemeData? selectedIconTheme,
  7. double? groupAlignment,
  8. NavigationRailLabelType? labelType,
  9. bool? useIndicator,
  10. Color? indicatorColor,
  11. ShapeBorder? indicatorShape,
  12. double? minWidth,
  13. double? minExtendedWidth}
)

Creates a copy of this object with the given fields replaced with the new values.

Implementation

NavigationRailThemeData copyWith({
  Color? backgroundColor,
  double? elevation,
  TextStyle? unselectedLabelTextStyle,
  TextStyle? selectedLabelTextStyle,
  IconThemeData? unselectedIconTheme,
  IconThemeData? selectedIconTheme,
  double? groupAlignment,
  NavigationRailLabelType? labelType,
  bool? useIndicator,
  Color? indicatorColor,
  ShapeBorder? indicatorShape,
  double? minWidth,
  double? minExtendedWidth,
}) {
  return NavigationRailThemeData(
    backgroundColor: backgroundColor ?? this.backgroundColor,
    elevation: elevation ?? this.elevation,
    unselectedLabelTextStyle: unselectedLabelTextStyle ?? this.unselectedLabelTextStyle,
    selectedLabelTextStyle: selectedLabelTextStyle ?? this.selectedLabelTextStyle,
    unselectedIconTheme: unselectedIconTheme ?? this.unselectedIconTheme,
    selectedIconTheme: selectedIconTheme ?? this.selectedIconTheme,
    groupAlignment: groupAlignment ?? this.groupAlignment,
    labelType: labelType ?? this.labelType,
    useIndicator: useIndicator ?? this.useIndicator,
    indicatorColor: indicatorColor ?? this.indicatorColor,
    indicatorShape: indicatorShape ?? this.indicatorShape,
    minWidth: minWidth ?? this.minWidth,
    minExtendedWidth: minExtendedWidth ?? this.minExtendedWidth,
  );
}