NiceButtons class

Inheritance

Constructors

NiceButtons({required Function onTap, required Widget child, Color startColor = const Color(0xFF2ec8ff), Color endColor = const Color(0xFF529fff), Color borderColor = const Color(0xFF3489e9), Color progressColor = Colors.white, double progressSize = 20, double borderRadius = 20, double borderThickness = 5, double height = 60, double width = 200, GradientOrientation gradientOrientation = GradientOrientation.Vertical, bool stretch = true, bool progress = false, bool disabled = false})

Properties

borderColor Color
The color of the 3D border of the button.
final
borderRadius double
The border radius for the button, defaults to 20.
final
borderThickness double
The thickness of the 3D border, defaults to 5.
final
br BorderRadius
The calculated border radius for the buttons.
final
calculatedWidth double
The calculated width of the button, sets to parent width when stretch property is set to true.
final
child Widget
Child widget that will be wrapped inside the button.
final
disabled bool
Disables the button, defaults to false.
final
endColor Color
The gradient end color to right when orientation is horizontal and to bottom when orientation is vertical.
final
gradientOrientation GradientOrientation
Orientation of the gradient defaults to Horizontal.
final
hashCode int
The hash code for this object.
no setterinherited
height double
Height of the button, defaults to 60.
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
onTap Function
Button on press handler, required.
final
progress bool
Whether the progress indicator is required or not, defaults to false.
final
progressColor Color
The color of circular progress indicator, defaults to white.
final
progressSize double
The size of progress indicator circle, defaults to 20.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
startColor Color
The gradient start color from left when gradientOrientation is horizontal, from top when orientation is vertical.
final
stretch bool
Whether to occupy the full available space in the parent, defaults to true.
final
width double
Width of the button defaults to 200, it's useless if the stretch property is set to true.
final

Methods

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