copyWith method
TxBorderSide
copyWith({
- Color? color,
- double? width,
- BorderStyle? style,
- LinearGradient? gradient,
- double? strokeAlign,
- List<
double> ? dashPattern,
override
Creates a copy of this border but with the given fields replaced with the new values.
Implementation
@override
TxBorderSide copyWith({
Color? color,
double? width,
BorderStyle? style,
LinearGradient? gradient,
double? strokeAlign,
List<double>? dashPattern,
}) {
assert(width == null || width >= 0.0);
return TxBorderSide(
color: color ?? this.color,
width: width ?? this.width,
style: style ?? this.style,
gradient: gradient ?? this.gradient,
dashPattern: dashPattern ?? this.dashPattern,
strokeAlign: strokeAlign ?? this.strokeAlign,
);
}