copyWith method
Span
copyWith({
- SpanExtent? extent,
- SpanPadding? padding,
- Map<
Type, GestureRecognizerFactory< ? recognizerFactories,GestureRecognizer> > - PointerEnterEventListener? onEnter,
- PointerExitEventListener? onExit,
- MouseCursor? cursor,
- SpanDecoration? backgroundDecoration,
- SpanDecoration? foregroundDecoration,
Create a clone of the current Span but with provided parameters overridden.
Implementation
Span copyWith({
SpanExtent? extent,
SpanPadding? padding,
Map<Type, GestureRecognizerFactory>? recognizerFactories,
PointerEnterEventListener? onEnter,
PointerExitEventListener? onExit,
MouseCursor? cursor,
SpanDecoration? backgroundDecoration,
SpanDecoration? foregroundDecoration,
}) {
return Span(
extent: extent ?? this.extent,
padding: padding ?? this.padding,
recognizerFactories: recognizerFactories ?? this.recognizerFactories,
onEnter: onEnter ?? this.onEnter,
onExit: onExit ?? this.onExit,
cursor: cursor ?? this.cursor,
backgroundDecoration: backgroundDecoration ?? this.backgroundDecoration,
foregroundDecoration: foregroundDecoration ?? this.foregroundDecoration,
);
}