copyWith method

BadgeThemeData copyWith({
  1. Color? backgroundColor,
  2. Color? textColor,
  3. double? smallSize,
  4. double? largeSize,
  5. TextStyle? textStyle,
  6. EdgeInsetsGeometry? padding,
  7. AlignmentGeometry? alignment,
  8. Offset? offset,
})

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

Implementation

BadgeThemeData copyWith({
  Color? backgroundColor,
  Color? textColor,
  double? smallSize,
  double? largeSize,
  TextStyle? textStyle,
  EdgeInsetsGeometry? padding,
  AlignmentGeometry? alignment,
  Offset? offset,
}) {
  return BadgeThemeData(
    backgroundColor: backgroundColor ?? this.backgroundColor,
    textColor: textColor ?? this.textColor,
    smallSize: smallSize ?? this.smallSize,
    largeSize: largeSize ?? this.largeSize,
    textStyle: textStyle ?? this.textStyle,
    padding: padding ?? this.padding,
    alignment: alignment ?? this.alignment,
    offset: offset ?? this.offset,
  );
}