copyWith method

  1. @override
UISegmentTabBarThemeData copyWith({
  1. Color? backgroundColor,
  2. Color? indicatorColor,
  3. Color? selectedForegroundColor,
  4. Color? unSelectedColor,
  5. Color? shadowColor,
  6. TextStyle? selectedTextStyle,
  7. TextStyle? unSelectedTextStyle,
  8. EdgeInsets? tabMargin,
  9. EdgeInsets? contentMargin,
  10. EdgeInsets? contentPadding,
  11. EdgeInsets? tabsPadding,
  12. BorderRadius? borderRadius,
  13. double? height,
})
override

Creates a copy of this theme extension with the given fields replaced by the non-null parameter values.

Implementation

@override
UISegmentTabBarThemeData copyWith({
  Color? backgroundColor,
  Color? indicatorColor,
  Color? selectedForegroundColor,
  Color? unSelectedColor,
  Color? shadowColor,
  TextStyle? selectedTextStyle,
  TextStyle? unSelectedTextStyle,
  EdgeInsets? tabMargin,
  EdgeInsets? contentMargin,
  EdgeInsets? contentPadding,
  EdgeInsets? tabsPadding,
  BorderRadius? borderRadius,
  double? height,
}) {
  return UISegmentTabBarThemeData(
    backgroundColor: backgroundColor ?? this.backgroundColor,
    indicatorColor: indicatorColor ?? this.indicatorColor,
    selectedForegroundColor: selectedForegroundColor ?? this.selectedForegroundColor,
    unSelectedColor: unSelectedColor ?? this.unSelectedColor,
    shadowColor: shadowColor ?? this.shadowColor,
    selectedTextStyle: selectedTextStyle ?? this.selectedTextStyle,
    unSelectedTextStyle: unSelectedTextStyle ?? this.unSelectedTextStyle,
    tabMargin: tabMargin ?? this.tabMargin,
    contentMargin: contentPadding ?? this.contentMargin,
    contentPadding: contentPadding ?? this.contentPadding,
    tabsPadding: tabsPadding ?? this.tabsPadding,
    borderRadius: borderRadius ?? this.borderRadius,
    height: height ?? this.height,
  );
}