WOITextBar class
The WOITextBar is a progress bar variation that has a text depicting progress which fills up based on the progress value.
Here is an example of the WOITextBar
const SizedBox(
child: WOITextBar(
progressValue: 10,
tiltValue: 0,
borderRadius: 30,
textStyle: TextStyle(
fontSize: 150,
fontWeight: FontWeight.bold,
height: 0,
),
boxBackgroundColor: Colors.red,
fillColor: Colors.orange,
textColor: Colors.black,
),
),
The size of the WOITextBar is adjusted by the font size of the widget. The progress value is a required field and should be between 0 and 100 inclusive.
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- WOITextBar
Constructors
- WOITextBar({Key? key, TextStyle textStyle = const TextStyle(fontSize: 150, fontWeight: FontWeight.bold, height: 0), Color boxBackgroundColor = Colors.yellow, Color fillColor = Colors.blueAccent, required int progressValue, int tiltValue = 0, Color textColor = Colors.black, double borderRadius = 20})
-
The WOITextBar is a progress bar variation that has a text depicting progress which fills up based on the progress value.
It takes an interger progressValue as a required parameter which should be between 0 and 100 inclusive. Border radius can not be more than 30
const
Properties
- borderRadius → double
-
This changes the border radius of the background of the WOITextBar. It cannot be more than 30.
final
- boxBackgroundColor → Color
-
Change color of the background of the widget. By default the color is yellow.
final
- fillColor → Color
-
This is the color that fills up the text as the progress value increases.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- progressValue → int
-
This is a required field that changes the progress being tracked by the WOITextBar.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- textColor → Color
-
This is used to change the color of the text.
final
- textStyle → TextStyle
-
Styling of the text. To change color of the text use WOITextBar's textColor property.
final
- tiltValue → int
-
Tilt value changes the tilt of the fill color. By default value is 0 which means no tilt. Negative value will give right tilt and positive value will give left tilt.
final
Methods
-
createElement(
) → StatefulElement -
Creates a StatefulElement to manage this widget's location in the tree.
inherited
-
createState(
) → State< WOITextBar> -
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