IDKitButton class

Inheritance

Constructors

IDKitButton({Key? key, double? width, double? height, Color? bgColor, Color? disableBgColor, String? backgroundImage, Decoration? decoration, Decoration? disableDecoration, String? title, String? disableTitle, String? image, String? disableImage, Size? imgSize, BoxFit? imgFit, BtnGraphicLayout layout = BtnGraphicLayout.lr, double? distance, EdgeInsetsGeometry? margin, EdgeInsetsGeometry? padding, TextStyle? style, TextStyle? disableStyle, dynamic onTap()?, bool enable = true, Stream<bool>? enableStream, Duration? duration})
const
IDKitButton.corner({double radius = 4, String? title, TextStyle? style, String? disableTitle, TextStyle? disableStyle, String? image, String? disableImage, Size? imgSize, BoxFit? imgFit, Color? bgColor, Color? disableBgColor, double? width, double? height, BtnCornerType cornerType = BtnCornerType.all, EdgeInsetsGeometry? margin, EdgeInsetsGeometry? padding, Duration? duration, dynamic onTap()?, bool enable = true, Stream<bool>? enableStream})
Buttons of the chamfer type series
factory
IDKitButton.gradient(List<Color> colors, {List<Color>? disableColors, BtnGradientType type = BtnGradientType.linear, List<double>? stops, TileMode tileMode = TileMode.clamp, AlignmentGeometry linearBegin = Alignment.centerLeft, AlignmentGeometry linearEnd = Alignment.centerRight, AlignmentGeometry center = Alignment.center, double radialRadius = 0.5, double sweepStartAngle = 0.0, double sweepEndAngle = math.pi * 2, String? title, TextStyle? style, String? disableTitle, TextStyle? disableStyle, String? image, String? disableImage, Size? imgSize, BoxFit? imgFit, double? width, double? height, EdgeInsetsGeometry? margin, EdgeInsetsGeometry? padding, double radius = 0, Duration? duration, dynamic onTap()?, bool enable = true, Stream<bool>? enableStream})
Gradient type button
factory
IDKitButton.image(String image, {String? disableImage, Size? imgSize, BoxFit? imgFit, Color? bgColor, Color? disableBgColor, Decoration? decoration, Decoration? disableDecoration, double? width, double? height, EdgeInsetsGeometry? margin, EdgeInsetsGeometry? padding, String? backgroundImage, Duration? duration, dynamic onTap()?, bool enable = true, Stream<bool>? enableStream})
Image-only button
factory
IDKitButton.imageAndText(String image, String title, {String? disableImage, Size? imgSize, BoxFit? imgFit, TextStyle? style, String? disableTitle, TextStyle? disableStyle, Color? bgColor, Color? disableBgColor, Decoration? decoration, Decoration? disableDecoration, double? width, double? height, EdgeInsetsGeometry? margin, EdgeInsetsGeometry? padding, double? distance, String? backgroundImage, BtnGraphicLayout layout = BtnGraphicLayout.lr, Duration? duration, dynamic onTap()?, bool enable = true, Stream<bool>? enableStream})
Image and text button
factory
IDKitButton.outline({Color borderColor = Colors.black, Color disableBorderColor = Colors.transparent, double borderWidth = 1.0, BorderStyle borderStyle = BorderStyle.solid, double radius = 0, Color? bgColor, Color? disableBgColor, String? title, TextStyle? style, String? disableTitle, TextStyle? disableStyle, String? image, String? disableImage, Size? imgSize, BoxFit? imgFit, double? width, double? height, EdgeInsetsGeometry? margin, EdgeInsetsGeometry? padding, Duration? duration, dynamic onTap()?, bool enable = true, Stream<bool>? enableStream})
Border type button
factory
IDKitButton.title(String title, {TextStyle? style, String? disableTitle, TextStyle? disableStyle, Color? bgColor, Color? disableBgColor, Decoration? decoration, Decoration? disableDecoration, double? width, double? height, EdgeInsetsGeometry? margin, EdgeInsetsGeometry? padding, String? backgroundImage, Duration? duration, dynamic onTap()?, bool enable = true, Stream<bool>? enableStream})
Text-only button
factory

Properties

backgroundImage String?
final
bgColor Color?
Button background color
final
decoration Decoration?
Button post decorator
final
disableBgColor Color?
Button non-interactive background color
final
disableDecoration Decoration?
final
disableImage String?
final
disableStyle TextStyle?
final
disableTitle String?
final
distance double?
Button image and text interval
final
duration Duration?
Button throttling time
final
enable bool
Button can be interactive
final
enableStream Stream<bool>?
Control buttons can interactive subscribers
final
hashCode int
The hash code for this object.
no setterinherited
height double?
final
image String?
Image of button
final
imgFit BoxFit?
Button image display mode
final
imgSize Size?
Button image size
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
layout BtnGraphicLayout
Button gradient mode type
final
margin EdgeInsetsGeometry?
Button's inner and outer margins
final
onTap → (dynamic Function()?)
Button click event callback
final
padding EdgeInsetsGeometry?
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
style TextStyle?
Button text style
final
title String?
Text of button
final
width double?
Button width and height
final

Methods

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