copyWith method
TextStyle
copyWith({
- bool? inherit,
- Color? color,
- Color? backgroundColor,
- double? fontSize,
- FontWeight? fontWeight,
- FontStyle? fontStyle,
- String? fontFamily,
- List<
String> ? fontFamilyFallback, - double? letterSpacing,
- double? wordSpacing,
- double? height,
- TextDecoration? decoration,
- Color? decorationColor,
- TextOverflow? overflow,
Implementation
TextStyle copyWith({
bool? inherit,
Color? color,
Color? backgroundColor,
double? fontSize,
FontWeight? fontWeight,
FontStyle? fontStyle,
String? fontFamily,
List<String>? fontFamilyFallback,
double? letterSpacing,
double? wordSpacing,
double? height,
TextDecoration? decoration,
Color? decorationColor,
TextOverflow? overflow,
}) => TextStyle(
inherit: inherit ?? this.inherit,
color: color ?? this.color,
backgroundColor: backgroundColor ?? this.backgroundColor,
fontSize: fontSize ?? this.fontSize,
fontWeight: fontWeight ?? this.fontWeight,
fontStyle: fontStyle ?? this.fontStyle,
fontFamily: fontFamily ?? this.fontFamily,
fontFamilyFallback: fontFamilyFallback ?? this.fontFamilyFallback,
letterSpacing: letterSpacing ?? this.letterSpacing,
wordSpacing: wordSpacing ?? this.wordSpacing,
height: height ?? this.height,
decoration: decoration ?? this.decoration,
decorationColor: decorationColor ?? this.decorationColor,
overflow: overflow ?? this.overflow,
);