copyWith method
KoiTextElement
copyWith({})
Implementation
KoiTextElement copyWith({
String? text,
KoiTextSize? size,
KoiTextSize? widthSize,
bool clearWidthSize = false,
KoiTextSize? heightSize,
bool clearHeightSize = false,
KoiTextAlign? align,
bool? bold,
bool? reverse,
bool? underline,
KoiUnderlineStyle? underlineStyle,
KoiFontType? font,
}) {
return KoiTextElement(
text: text ?? this.text,
size: size ?? this.size,
widthSize: clearWidthSize ? null : (widthSize ?? this.widthSize),
heightSize: clearHeightSize ? null : (heightSize ?? this.heightSize),
align: align ?? this.align,
bold: bold ?? this.bold,
reverse: reverse ?? this.reverse,
underline: underline ?? this.underline,
underlineStyle: underlineStyle ?? this.underlineStyle,
font: font ?? this.font,
);
}