PlutoScrollbar constructor
const
PlutoScrollbar({
- Key? key,
- ScrollController? horizontalController,
- ScrollController? verticalController,
- bool isAlwaysShown = false,
- bool onlyDraggingThumb = true,
- bool enableHover = true,
- double thickness = defaultThickness,
- double thicknessWhileDragging = defaultThicknessWhileDragging,
- double hoverWidth = defaultScrollbarHoverWidth,
- double? mainAxisMargin,
- double? crossAxisMargin,
- Color? scrollBarColor,
- Color? scrollBarTrackColor,
- Radius radius = defaultRadius,
- Radius radiusWhileDragging = defaultRadiusWhileDragging,
- required Widget child,
Implementation
const PlutoScrollbar({
Key? key,
this.horizontalController,
this.verticalController,
this.isAlwaysShown = false,
this.onlyDraggingThumb = true,
this.enableHover = true,
this.thickness = defaultThickness,
this.thicknessWhileDragging = defaultThicknessWhileDragging,
this.hoverWidth = defaultScrollbarHoverWidth,
double? mainAxisMargin,
double? crossAxisMargin,
Color? scrollBarColor,
Color? scrollBarTrackColor,
this.radius = defaultRadius,
this.radiusWhileDragging = defaultRadiusWhileDragging,
required this.child,
}) : assert(thickness < double.infinity),
assert(thicknessWhileDragging < double.infinity),
assert(!isAlwaysShown ||
(horizontalController != null || verticalController != null)),
mainAxisMargin = mainAxisMargin ?? _kScrollbarMainAxisMargin,
crossAxisMargin = crossAxisMargin ?? _kScrollbarCrossAxisMargin,
scrollBarColor = scrollBarColor ?? _kScrollbarColor,
scrollBarTrackColor = scrollBarTrackColor ?? _kTrackColor,
super(key: key);