copyWith method
ParentNodeTheme<T>
copyWith({
- Widget? widget,
- Widget? widgetResolver(
- Node<
T> node
- Node<
- Widget? openWidget,
- Widget? openWidgetResolver(
- Node<
T> node
- Node<
- double? width,
- double? height,
- EdgeInsets? padding,
- EdgeInsets? margin,
- TextStyle? textStyle,
- TextStyle? textStyleResolver(
- Node<
T> node
- Node<
- String? labelResolver(
- Node<
T> node
- Node<
- Color? hoverColor,
- Color? splashColor,
- Color? highlightColor,
- NodeTooltipTheme<
T> ? tooltipTheme,
Creates a copy of this theme with the given fields replaced with new values
Implementation
ParentNodeTheme<T> copyWith({
Widget? widget,
Widget? Function(Node<T> node)? widgetResolver,
Widget? openWidget,
Widget? Function(Node<T> node)? openWidgetResolver,
double? width,
double? height,
EdgeInsets? padding,
EdgeInsets? margin,
TextStyle? textStyle,
TextStyle? Function(Node<T> node)? textStyleResolver,
String? Function(Node<T> node)? labelResolver,
Color? hoverColor,
Color? splashColor,
Color? highlightColor,
NodeTooltipTheme<T>? tooltipTheme,
}) {
return ParentNodeTheme<T>(
widget: widget ?? this.widget,
widgetResolver: widgetResolver ?? this.widgetResolver,
openWidget: openWidget ?? this.openWidget,
openWidgetResolver: openWidgetResolver ?? this.openWidgetResolver,
width: width ?? this.width,
height: height ?? this.height,
padding: padding ?? this.padding,
margin: margin ?? this.margin,
textStyle: textStyle ?? this.textStyle,
textStyleResolver: textStyleResolver ?? this.textStyleResolver,
labelResolver: labelResolver ?? this.labelResolver,
hoverColor: hoverColor ?? this.hoverColor,
splashColor: splashColor ?? this.splashColor,
highlightColor: highlightColor ?? this.highlightColor,
tooltipTheme: tooltipTheme ?? this.tooltipTheme,
);
}