TabPages class
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- TabPages
Constructors
-
TabPages({Key? key, List<
Widget> ? tabs, List<Widget> ? pages, double tabHeight = 40, Color tabBackgroundColor = Colors.transparent, Color? selectedLabelColor, Color? unselectedLabelColor, double indicatorWeight = 2, Color? indicatorColor, EdgeInsetsGeometry indicatorPadding = EdgeInsets.zero, int initialIndex = 0, TabBuildCallback? buildCallback, TabChangeListener? change, bool isScrollable = true, TextStyle? selectedLabelStyle, TextStyle? unselectedLabelStyle, TabPageStyle style = TabPageStyle.normal, double elevation = 0.8, Color elevationColor = const Color(0xFFEEEEEE), double topViewHeight = 0, Widget? topWidget, String title = "", Color titleColor = const Color(0xff333333), List<Widget> ? actions, double? paddingTop, Widget? backIcon, VoidCallback? backClick, String? indicatorImageNameOrAlias, double? imageIndicatorOffsetDy, BorderRadius? tabBorderRadius, double? indicatorBaseLineWeight, Color? indicatorBaseLineColor, EdgeInsetsGeometry? indicatorBaseLineMargin, bool enableActionBarGradient = false, double customActionBarHeight = 0, dynamic loadCall(BuildContext context)?, Color? tabBarViewBackground, ScrollController? scrollController, double scrollMaxRatioLoad = 0.7}) -
const
Properties
-
actions
→ List<
Widget> ? -
app bar 右边按钮
final
- backClick → VoidCallback?
-
返回事件
final
- backIcon → Widget?
-
返回按钮
final
- buildCallback → TabBuildCallback?
-
tab组件构建完成回调
final
- change → TabChangeListener?
-
选项改变监听
final
- customActionBarHeight → double
-
自定义ActionBar高度
final
- elevation → double
-
tab bar下面分割线高度
final
- elevationColor → Color
-
tab bar下面分割线颜色(isHiddenAppBar==false时值无效)
final
- enableActionBarGradient → bool
-
启用ActionBar渐变
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- imageIndicatorOffsetDy → double?
-
图片指示器垂直偏移量
final
- indicatorBaseLineColor → Color?
-
选择器基线颜色
final
- indicatorBaseLineMargin → EdgeInsetsGeometry?
-
选择器基线外边距
final
- indicatorBaseLineWeight → double?
-
选择器基线权重值
final
- indicatorColor → Color?
-
指示器颜色
final
- indicatorImageNameOrAlias → String?
-
指示器图片名字和别名
final
- indicatorPadding → EdgeInsetsGeometry
-
指示器边距(可以控制指示器宽度)
final
- indicatorWeight → double
-
指示器线的粗细
final
- initialIndex → int
-
初始化选项卡索引
final
- isScrollable → bool
-
tab是否允许滚动(默认true)
final
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- loadCall → dynamic Function(BuildContext context)?
-
TabPageStyle.pageSuckTop
组件加载时回调final - paddingTop → double?
-
tab page上边距
final
-
pages
→ List<
Widget> ? -
选项内容页面
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- scrollController → ScrollController?
-
TabPageStyle.pageSuckTop
类型Refresh controllerfinal - scrollMaxRatioLoad → double
-
滚动超过最大比例加载下一页数据(范围:0~1)
final
- selectedLabelColor → Color?
-
选择文本颜色
final
- selectedLabelStyle → TextStyle?
-
tab选中文本样式
final
- style → TabPageStyle
-
tabPage样式
final
- tabBackgroundColor → Color
-
选项卡背景
final
- tabBarViewBackground → Color?
-
TabPageStyle.pageSuckTop
类型TabBarView背景颜色final - tabBorderRadius → BorderRadius?
-
tab边框圆角
final
- tabHeight → double
-
选项卡高度(默认40)
final
-
tabs
→ List<
Widget> ? -
选项
final
- title → String
-
app bar title
final
- titleColor → Color
-
标题颜色
final
- topViewHeight → double
-
指style==TabPageStyle.suckTop时tab至顶部之间的视图高度
final
- topWidget → Widget?
-
顶部视图组件
final
- unselectedLabelColor → Color?
-
未选择文本颜色
final
- unselectedLabelStyle → TextStyle?
-
tab未选中文本样式
final
Methods
-
createElement(
) → StatefulElement -
Creates a StatefulElement to manage this widget's location in the tree.
inherited
-
createState(
) → _TabPagesState -
Creates the mutable state for this widget at a given location in the tree.
override
-
debugDescribeChildren(
) → List< DiagnosticsNode> -
Returns a list of DiagnosticsNode objects describing this node's
children.
inherited
-
debugFillProperties(
DiagnosticPropertiesBuilder properties) → void -
Add additional properties associated with the node.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toDiagnosticsNode(
{String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode -
Returns a debug representation of the object that is used by debugging
tools and by DiagnosticsNode.toStringDeep.
inherited
-
toString(
{DiagnosticLevel minLevel = DiagnosticLevel.info}) → String -
A string representation of this object.
inherited
-
toStringDeep(
{String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) → String -
Returns a string representation of this node and its descendants.
inherited
-
toStringShallow(
{String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String -
Returns a one-line detailed description of the object.
inherited
-
toStringShort(
) → String -
A short, textual description of this widget.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited