copyWith method

TextMetadata copyWith({
  1. Color? color,
  2. FontWeight? fontWeight,
  3. FontStyle? fontStyle,
  4. double? fontSize,
  5. TextDecorationEnum? decoration,
  6. List<FontFeature>? fontFeatures,
  7. TextAlign? alignment,
})

Implementation

TextMetadata copyWith({
  Color? color,
  FontWeight? fontWeight,
  FontStyle? fontStyle,
  double? fontSize,
  TextDecorationEnum? decoration,
  List<FontFeature>? fontFeatures,
  TextAlign? alignment,
}) {
  return TextMetadata(
    color: color ?? this.color,
    fontWeight: fontWeight ?? this.fontWeight,
    fontStyle: fontStyle ?? this.fontStyle,
    fontSize: fontSize ?? this.fontSize,
    decoration: decoration ?? this.decoration,
    fontFeatures: fontFeatures ?? this.fontFeatures,
    alignment: alignment ?? this.alignment,
  );
}