DrivenToggleIconStyle class

A ToggleIconStyle that change when some events occurs.

Inheritance
Implemented types

Constructors

DrivenToggleIconStyle({double? size, Color? color, double? opacity, double? scale, Color? backColor, double? backOpacity, ToggleIconStyle? selectedStyle, ToggleIconStyle? disabledStyle, bool? mergeResolved})
Create a ToggleIconStyle that change when some events occurs.
const
DrivenToggleIconStyle.fade({double? size, Color? color, Color? backColor, ToggleIconStyle? selectedStyle, ToggleIconStyle? disabledStyle})
DrivenToggleIconStyle.from(ToggleIconStyle? enabled, {ToggleIconStyle? selectedStyle, ToggleIconStyle? disabledStyle, bool? mergeResolved})
Create a DrivenToggleIconStyle with value from another ToggleIconStyle.
DrivenToggleIconStyle.resolver(DrivenPropertyResolver<ToggleIconStyle?> resolver, {bool? mergeResolved = false})
Create a DrivenToggleIconStyle from a resolver callback
DrivenToggleIconStyle.scaleDown({double? size, Color? color, Color? backColor, ToggleIconStyle? selectedStyle, ToggleIconStyle? disabledStyle})
DrivenToggleIconStyle.scaleUp({double? size, Color? color, Color? backColor, ToggleIconStyle? selectedStyle, ToggleIconStyle? disabledStyle})

Properties

backColor Color?
The color to use when drawing the back icon.
finalinherited
backOpacity double?
Opacity to be apply to backColor.
finalinherited
color Color?
The color to use when drawing the icon.
finalinherited
disabledStyle ToggleIconStyle?
The disabledStyle style to be resolved when events includes WidgetEvent.disabled.
final
driven Map<WidgetEvent, ToggleIconStyle?>
Map of driven style, order matters
no setter
hashCode int
The hash code for this object.
no setterinherited
mergeResolved bool?
Whether the resolved style is merged to the previous resolved style or not
final
opacity double?
Opacity to be apply to color.
finalinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
scale double?
Scale the size of the icon.
finalinherited
selectedStyle ToggleIconStyle?
The selectedStyle is style to be resolved when events includes WidgetEvent.selected.
final
size double?
The size of the icon in logical pixels.
finalinherited

Methods

copyWith({double? size, Color? color, double? opacity, double? scale, Color? backColor, double? backOpacity, bool? mergeResolved, ToggleIconStyle? selectedStyle, ToggleIconStyle? disabledStyle}) DrivenToggleIconStyle
Creates a copy of this ToggleIconStyle but with the given fields replaced with the new values.
override
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
override
merge(ToggleIconStyle? other) ToggleIconStyle
Creates a copy of this ToggleIconStyle but with the given fields replaced with the new values.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
resolve(Set<WidgetEvent> events) ToggleIconStyle
Returns a value of type T that depends on events.
override
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toMap() Map<String, dynamic>
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) String
A string representation of this object.
inherited
toStringShort() String
A brief description of this object, usually just the runtimeType and the hashCode.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

evaluate(ToggleIconStyle? value, Set<WidgetEvent> events) ToggleIconStyle?
Resolves the value for the given set of events if value is an event driven ToggleIconStyle, otherwise returns the value itself.
override