BrnProgressChart class
一个简单的进度条 Widget,支持数据变化时的动画
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- BrnProgressChart
- Available Extensions
Constructors
-
BrnProgressChart({Key? key, double width = 0, double height = 0, double value = 0.2, double indicatorLeftPadding = 10, TextStyle textStyle = const TextStyle(color: Colors.white), BrnProgressIndicatorBuilder? brnProgressIndicatorBuilder, List<
Color> colors = const [Colors.blueAccent, Colors.blue], Color backgroundColor = Colors.lightBlueAccent, bool showAnimation = false, bool isFromLastValue = false, Duration duration = const Duration(milliseconds: 250)}) -
const
Properties
- backgroundColor → Color
-
背景色,默认 Colors.lightBlueAccent
final
- brnProgressIndicatorBuilder → BrnProgressIndicatorBuilder?
-
自定义进度条上面的Widget,默认显示为文本
final
-
colors
→ List<
Color> -
进度条颜色,默认
Colors.blueAccent, Colors.blue
final - duration → Duration
-
动画时长,默认 Duration(milliseconds: 250)
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- height → double
-
高度,默认0
final
- indicatorLeftPadding → double
-
进度条上自定义Widget的左侧padding,默认值10
final
- isFromLastValue → bool
-
进度条是否从上次的值开始
final
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- showAnimation → bool
-
是否展示动画,默认 false
final
- textStyle → TextStyle
-
展示默认进度indicator的时候的文本样式,默认 TextStyle(color: Colors.white)
final
- value → double
-
进度图进度值,默认0.2,必须在 0 到 1 之间
final
- width → double
-
宽度,默认0
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