copyWith method
DynamicTextStyle
copyWith({
- Color? color,
- Color? backgroundColor,
- String? fontFamily,
- Dimension? fontSize,
- FontWeight? fontWeight,
- FontStyle? fontStyle,
- Dimension? letterSpacing,
- Dimension? wordSpacing,
- double? height,
- Paint? foreground,
- Paint? background,
- List<
Shadow> ? shadows, - TextDecoration? decoration,
- Color? decorationColor,
- TextDecorationStyle? decorationStyle,
- double? decorationThickness,
Implementation
DynamicTextStyle copyWith({
Color? color,
Color? backgroundColor,
String? fontFamily,
Dimension? fontSize,
FontWeight? fontWeight,
FontStyle? fontStyle,
Dimension? letterSpacing,
Dimension? wordSpacing,
double? height,
Paint? foreground,
Paint? background,
List<Shadow>? shadows,
TextDecoration? decoration,
Color? decorationColor,
TextDecorationStyle? decorationStyle,
double? decorationThickness,
}) {
return DynamicTextStyle(
color: color ?? this.color,
backgroundColor: backgroundColor ?? this.backgroundColor,
fontFamily: fontFamily ?? this.fontFamily,
fontSize: fontSize ?? this.fontSize,
fontWeight: fontWeight ?? this.fontWeight,
fontStyle: fontStyle ?? this.fontStyle,
letterSpacing: letterSpacing ?? this.letterSpacing,
wordSpacing: wordSpacing ?? this.wordSpacing,
height: height ?? this.height,
shadows: shadows ?? this.shadows,
decoration: decoration ?? this.decoration,
decorationColor: decorationColor ?? this.decorationColor,
decorationStyle: decorationStyle ?? this.decorationStyle,
decorationThickness: decorationThickness ?? this.decorationThickness,
);
}