copyWith method

DynamicTextStyle copyWith({
  1. Color? color,
  2. Color? backgroundColor,
  3. String? fontFamily,
  4. Dimension? fontSize,
  5. FontWeight? fontWeight,
  6. FontStyle? fontStyle,
  7. Dimension? letterSpacing,
  8. Dimension? wordSpacing,
  9. double? height,
  10. Paint? foreground,
  11. Paint? background,
  12. List<Shadow>? shadows,
  13. TextDecoration? decoration,
  14. Color? decorationColor,
  15. TextDecorationStyle? decorationStyle,
  16. 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,
  );
}