copyWith method
DrivenChipStyle
copyWith({
- ChipVariant? variant,
- ChipSeverity? severity,
- double? width,
- double? height,
- EdgeInsetsGeometry? margin,
- EdgeInsetsGeometry? padding,
- Alignment? alignment,
- Clip? clipBehavior,
- bool? overlayDisabled,
- Color? overlayColor,
- Color? shadowColor,
- Color? surfaceTint,
- double? elevation,
- TextStyle? foregroundStyle,
- Color? foregroundColor,
- double? foregroundOpacity,
- int? foregroundAlpha,
- double? foregroundSpacing,
- bool? foregroundLoosen,
- bool? foregroundExpanded,
- CrossAxisAlignment? foregroundAlign,
- MainAxisAlignment? foregroundJustify,
- Color? backgroundColor,
- double? backgroundOpacity,
- int? backgroundAlpha,
- Color? borderColor,
- double? borderOpacity,
- int? borderAlpha,
- double? borderWidth,
- BorderRadius? borderRadius,
- BorderStyle? borderStyle,
- BoxShape? shape,
- Color? iconColor,
- double? iconOpacity,
- double? iconSize,
- AvatarStyle? avatarStyle,
- Color? checkmarkColor,
- double? checkmarkSize,
- double? checkmarkWeight,
- StrokeStyle? checkmarkStyle,
- bool? mergeResolved,
- ChipStyle? selectedStyle,
- ChipStyle? disabledStyle,
- ChipStyle? hoveredStyle,
- ChipStyle? focusedStyle,
- ChipStyle? pressedStyle,
override
Creates a copy of this DrivenChipStyle but with the given fields replaced with the new values.
Implementation
@override
DrivenChipStyle copyWith({
ChipVariant? variant,
ChipSeverity? severity,
double? width,
double? height,
EdgeInsetsGeometry? margin,
EdgeInsetsGeometry? padding,
Alignment? alignment,
Clip? clipBehavior,
bool? overlayDisabled,
Color? overlayColor,
Color? shadowColor,
Color? surfaceTint,
double? elevation,
TextStyle? foregroundStyle,
Color? foregroundColor,
double? foregroundOpacity,
int? foregroundAlpha,
double? foregroundSpacing,
bool? foregroundLoosen,
bool? foregroundExpanded,
CrossAxisAlignment? foregroundAlign,
MainAxisAlignment? foregroundJustify,
Color? backgroundColor,
double? backgroundOpacity,
int? backgroundAlpha,
Color? borderColor,
double? borderOpacity,
int? borderAlpha,
double? borderWidth,
BorderRadius? borderRadius,
BorderStyle? borderStyle,
BoxShape? shape,
Color? iconColor,
double? iconOpacity,
double? iconSize,
AvatarStyle? avatarStyle,
Color? checkmarkColor,
double? checkmarkSize,
double? checkmarkWeight,
StrokeStyle? checkmarkStyle,
bool? mergeResolved,
ChipStyle? selectedStyle,
ChipStyle? disabledStyle,
ChipStyle? hoveredStyle,
ChipStyle? focusedStyle,
ChipStyle? pressedStyle,
}) {
return DrivenChipStyle(
variant: variant ?? this.variant,
severity: severity ?? this.severity,
height: height ?? this.height,
margin: margin ?? this.margin,
padding: padding ?? this.padding,
clipBehavior: clipBehavior ?? this.clipBehavior,
overlayDisabled: overlayDisabled ?? this.overlayDisabled,
overlayColor: overlayColor ?? this.overlayColor,
shadowColor: shadowColor ?? this.shadowColor,
surfaceTint: surfaceTint ?? this.surfaceTint,
elevation: elevation ?? this.elevation,
foregroundStyle: foregroundStyle ?? this.foregroundStyle,
foregroundColor: foregroundColor ?? this.foregroundColor,
foregroundOpacity: foregroundOpacity ?? this.foregroundOpacity,
foregroundAlpha: foregroundAlpha ?? this.foregroundAlpha,
foregroundSpacing: foregroundSpacing ?? this.foregroundSpacing,
foregroundLoosen: foregroundLoosen ?? this.foregroundLoosen,
foregroundExpanded: foregroundExpanded ?? this.foregroundExpanded,
foregroundAlign: foregroundAlign ?? this.foregroundAlign,
foregroundJustify: foregroundJustify ?? this.foregroundJustify,
backgroundColor: backgroundColor ?? this.backgroundColor,
backgroundOpacity: backgroundOpacity ?? this.backgroundOpacity,
backgroundAlpha: backgroundAlpha ?? this.backgroundAlpha,
borderColor: borderColor ?? this.borderColor,
borderOpacity: borderOpacity ?? this.borderOpacity,
borderAlpha: borderAlpha ?? this.borderAlpha,
borderWidth: borderWidth ?? this.borderWidth,
borderRadius: borderRadius ?? this.borderRadius,
borderStyle: borderStyle ?? this.borderStyle,
iconColor: iconColor ?? this.iconColor,
iconOpacity: iconOpacity ?? this.iconOpacity,
iconSize: iconSize ?? this.iconSize,
avatarStyle: AvatarStyle.from(this.avatarStyle).merge(avatarStyle),
checkmarkColor: checkmarkColor ?? this.checkmarkColor,
checkmarkSize: checkmarkSize ?? this.checkmarkSize,
checkmarkWeight: checkmarkWeight ?? this.checkmarkWeight,
checkmarkStyle: checkmarkStyle ?? this.checkmarkStyle,
mergeResolved: mergeResolved ?? this.mergeResolved,
selectedStyle: this.selectedStyle?.merge(selectedStyle) ?? selectedStyle,
focusedStyle: this.focusedStyle?.merge(focusedStyle) ?? focusedStyle,
hoveredStyle: this.hoveredStyle?.merge(hoveredStyle) ?? hoveredStyle,
pressedStyle: this.pressedStyle?.merge(pressedStyle) ?? pressedStyle,
disabledStyle: this.disabledStyle?.merge(disabledStyle) ?? disabledStyle,
);
}