FolderTabBar constructor
FolderTabBar({
- Key? key,
- required List<
TabItem> tabs, - TabController? controller,
- double selectedHeight = 40.0,
- double unselectedHeight = 32.0,
- double indicatorHeight = 4.0,
- double topPadding = 8.0,
- double verticalTabPadding = 2.0,
- ShapeBorder tabShape = const RoundedRectangleBorder(borderRadius: BorderRadius.only(topLeft: Radius.circular(4.0), topRight: Radius.circular(4.0))),
- Color? labelColor,
- Color? unselectedLabelColor,
- TextStyle? labelStyle,
- TextStyle? unselectedLabelStyle,
- TabAxisAlignment alignment = TabAxisAlignment.center,
Implementation
FolderTabBar({
super.key,
required this.tabs,
this.controller,
double selectedHeight = 40.0,
double unselectedHeight = 32.0,
this.indicatorHeight = 4.0,
this.topPadding = 8.0,
this.verticalTabPadding = 2.0,
this.tabShape = const RoundedRectangleBorder(
borderRadius: BorderRadius.only(
topLeft: Radius.circular(4.0),
topRight: Radius.circular(4.0),
)),
this.labelColor,
this.unselectedLabelColor,
this.labelStyle,
this.unselectedLabelStyle,
TabAxisAlignment alignment = TabAxisAlignment.center,
}) : assert(selectedHeight > 0.0),
assert(unselectedHeight > 0.0),
assert(indicatorHeight >= 0.0),
_tabHeight = max(selectedHeight, unselectedHeight),
_selectedTabPadding =
max(selectedHeight, unselectedHeight) - selectedHeight,
_unselectedTabPadding =
max(selectedHeight, unselectedHeight) - unselectedHeight,
_alignment = alignment.toCrossAxisAlignment();