copyWith static method
Makes a copy of the nearest TreeTheme overwriting selected fields.
Implementation
static Widget copyWith({
Key? key,
required Widget child,
TextStyle? textStyle,
Color? color,
Color? hoverColor,
Color? highlightColor,
}) {
return Builder(
key: key,
builder: (context) => TreeTheme(
data: TreeTheme.of(context).copyWith(
textStyle: textStyle,
color: color,
hoverColor: hoverColor,
highlightColor: highlightColor,
),
child: child,
),
);
}