copyWith method
- @useResult
- FWidgetStateMap<
Color?> ? backgroundColor, - EdgeInsetsGeometry? margin,
- FWidgetStateMap<
BoxDecoration?> ? decoration, - FItemContentStyle contentStyle(
- FItemContentStyle style
- FRawItemContentStyle rawItemContentStyle(
- FRawItemContentStyle style
- FTappableStyle tappableStyle(
- FTappableStyle style
- FFocusedOutlineStyle? focusedOutlineStyle,
Returns a copy of this FTileStyle with the given properties replaced.
Consider using the CLI to generate a style.
Parameters
- FTileStyle.backgroundColor - The item's background color.
- FTileStyle.margin - The margin around the item, including the
decoration
. - FTileStyle.decoration - The item's decoration.
- FTileStyle.contentStyle - The default item content's style.
- FTileStyle.rawItemContentStyle - THe default raw item content's style.
- FTileStyle.tappableStyle - The tappable style.
- FTileStyle.focusedOutlineStyle - The focused outline style.
Implementation
@useResult
FTileStyle copyWith({
FWidgetStateMap<Color?>? backgroundColor,
EdgeInsetsGeometry? margin,
FWidgetStateMap<BoxDecoration?>? decoration,
FItemContentStyle Function(FItemContentStyle style)? contentStyle,
FRawItemContentStyle Function(FRawItemContentStyle style)? rawItemContentStyle,
FTappableStyle Function(FTappableStyle style)? tappableStyle,
FFocusedOutlineStyle? focusedOutlineStyle,
}) => FTileStyle(
backgroundColor: backgroundColor ?? this.backgroundColor,
margin: margin ?? this.margin,
decoration: decoration ?? this.decoration,
contentStyle: contentStyle != null ? contentStyle(this.contentStyle) : this.contentStyle,
rawItemContentStyle: rawItemContentStyle != null
? rawItemContentStyle(this.rawItemContentStyle)
: this.rawItemContentStyle,
tappableStyle: tappableStyle != null ? tappableStyle(this.tappableStyle) : this.tappableStyle,
focusedOutlineStyle: focusedOutlineStyle ?? this.focusedOutlineStyle,
);