FlSwiper class

Inheritance
Available Extensions

Constructors

FlSwiper({Key? key, required IndexedWidgetBuilder itemBuilder, required int itemCount, bool autoPlay = true, FlSwiperLayout layout = FlSwiperLayout.stack, Duration duration = kDefaultAutoPlayDelay, Duration transitionDuration = kDefaultAutoPlayTransitionDuration, List<FlSwiperPlugin> pagination = const <FlSwiperPlugin>[], ValueChanged<int>? onChanged, int? index, FlSwiperOnTap? onTap, bool loop = true, Curve curve = Curves.ease, Axis scrollDirection = Axis.horizontal, FlSwiperController? controller, required double itemHeight, required double itemWidth})
const

Properties

autoPlay bool
auto play config 自动播放开关.
final
controller FlSwiperController?
控制器
final
curve Curve
transition curve
final
duration Duration
Animation duration
final
hashCode int
The hash code for this object.
no setterinherited
index int?
Index number of initial slide. If not set , the FlSwiper is 'uncontrolled', which means manage index by itself If set , the FlSwiper is 'controlled', which means the index is fully managed by parent widget. 初始的时候下标位置
final
itemBuilder IndexedWidgetBuilder
Build item on index
final
itemCount int
count of the display items
final
itemHeight double
Inner item height, this property is valid if layout=stack or layout=tinder,
final
itemWidth double
Inner item width, this property is valid if layout=stack or layout=tinder,
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
layout FlSwiperLayout
Build in layouts
final
loop bool
Set to false to disable continuous loop mode. 无限轮播模式开关
final
onChanged ValueChanged<int>?
当用户手动拖拽或者自动播放引起下标改变的时候调用
final
onTap FlSwiperOnTap?
Called when tap 当用户点击某个轮播的时候调用
final
pagination List<FlSwiperPlugin>
other plugins, you can custom your own plugin
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
scrollDirection Axis
horizontal/vertical
final
transitionDuration Duration
play transition duration
final

Methods

createElement() StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() State<StatefulWidget>
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}) 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