CIconButton class
Constructors
CIconButton ({Key ? key , double ? iconSize , VisualDensity ? visualDensity , EdgeInsetsGeometry ? padding , AlignmentGeometry ? alignment , double ? splashRadius , Color ? color , Color ? focusColor , Color ? hoverColor , Color ? highlightColor , Color ? splashColor , Color ? disabledColor , required VoidCallback ? onPressed , MouseCursor ? mouseCursor , FocusNode ? focusNode , bool autofocus = false , String ? tooltip , bool ? enableFeedback , BoxConstraints ? constraints , CButtonStyle ? style , bool ? isSelected , Widget ? selectedIcon , required Widget icon , bool ? loading , bool ? canRequestFocus })
const
CIconButton.filled ({Key ? key , double ? iconSize , VisualDensity ? visualDensity , EdgeInsetsGeometry ? padding , AlignmentGeometry ? alignment , double ? splashRadius , Color ? color , Color ? focusColor , Color ? hoverColor , Color ? highlightColor , Color ? splashColor , Color ? disabledColor , required VoidCallback ? onPressed , MouseCursor ? mouseCursor , FocusNode ? focusNode , bool autofocus = false , String ? tooltip , bool ? enableFeedback , BoxConstraints ? constraints , CButtonStyle ? style , bool ? isSelected , Widget ? selectedIcon , required Widget icon , bool ? loading , bool ? canRequestFocus })
Create a filled variant of CIconButton.
const
CIconButton.filledTonal ({Key ? key , double ? iconSize , VisualDensity ? visualDensity , EdgeInsetsGeometry ? padding , AlignmentGeometry ? alignment , double ? splashRadius , Color ? color , Color ? focusColor , Color ? hoverColor , Color ? highlightColor , Color ? splashColor , Color ? disabledColor , required VoidCallback ? onPressed , MouseCursor ? mouseCursor , FocusNode ? focusNode , bool autofocus = false , String ? tooltip , bool ? enableFeedback , BoxConstraints ? constraints , CButtonStyle ? style , bool ? isSelected , Widget ? selectedIcon , required Widget icon , bool ? loading , bool ? canRequestFocus })
Create a filled tonal variant of CIconButton.
const
CIconButton.outlined ({Key ? key , double ? iconSize , VisualDensity ? visualDensity , EdgeInsetsGeometry ? padding , AlignmentGeometry ? alignment , double ? splashRadius , Color ? color , Color ? focusColor , Color ? hoverColor , Color ? highlightColor , Color ? splashColor , Color ? disabledColor , required VoidCallback ? onPressed , MouseCursor ? mouseCursor , FocusNode ? focusNode , bool autofocus = false , String ? tooltip , bool ? enableFeedback , BoxConstraints ? constraints , CButtonStyle ? style , bool ? isSelected , Widget ? selectedIcon , required Widget icon , bool ? loading , bool ? canRequestFocus })
Create a filled tonal variant of CIconButton.
const
Properties
alignment
→ AlignmentGeometry ?
Defines how the icon is positioned within the IconButton.
final inherited
autofocus
→ bool
True if this widget will be selected as the initial focus when no other
node in its scope is currently focused.
final inherited
canRequestFocus
→ bool ?
final
color
→ Color ?
The color to use for the icon inside the button, if the icon is enabled.
Defaults to leaving this up to the icon widget.
final inherited
constraints
→ BoxConstraints ?
Optional size constraints for the button.
final inherited
cStyle
→ CButtonStyle ?
final
disabledColor
→ Color ?
The color to use for the icon inside the button, if the icon is disabled.
Defaults to the ThemeData.disabledColor of the current Theme .
final inherited
enableFeedback
→ bool ?
Whether detected gestures should provide acoustic and/or haptic feedback.
final inherited
focusColor
→ Color ?
The color for the button when it has the input focus.
final inherited
focusNode
→ FocusNode ?
An optional focus node to use as the focus node for this widget.
final inherited
hashCode
→ int
The hash code for this object.
no setter inherited
highlightColor
→ Color ?
The secondary color of the button when the button is in the down (pressed)
state. The highlight color is represented as a solid color that is overlaid over the
button color (if any). If the highlight color has transparency, the button color
will show through. The highlight fades in quickly as the button is held down.
final inherited
hoverColor
→ Color ?
The color for the button when a pointer is hovering over it.
final inherited
icon
→ Widget
The icon to display inside the button.
final inherited
iconSize
→ double ?
The size of the icon inside the button.
final inherited
isSelected
→ bool ?
The optional selection state of the icon button.
final inherited
key
→ Key ?
Controls how one widget replaces another widget in the tree.
final inherited
loading
→ bool ?
final
mouseCursor
→ MouseCursor ?
The cursor for a mouse pointer when it enters or is hovering over the
button.
final inherited
onPressed
→ VoidCallback ?
The callback that is called when the button is tapped or otherwise activated.
final inherited
padding
→ EdgeInsetsGeometry ?
The padding around the button's icon. The entire padded icon will react
to input gestures.
final inherited
runtimeType
→ Type
A representation of the runtime type of the object.
no setter inherited
selectedIcon
→ Widget ?
The icon to display inside the button when isSelected is true. This property
can be null. The original icon will be used for both selected and unselected
status if it is null.
final inherited
splashColor
→ Color ?
The primary color of the button when the button is in the down (pressed) state.
The splash is represented as a circular overlay that appears above the
highlightColor overlay. The splash overlay has a center point that matches
the hit point of the user touch event. The splash overlay will expand to
fill the button area if the touch is held for long enough time. If the splash
color has transparency then the highlight and button color will show through.
final inherited
splashRadius
→ double ?
The splash radius.
final inherited
style
→ ButtonStyle ?
Customizes this button's appearance.
final inherited
tooltip
→ String ?
Text that describes the action that will occur when the button is pressed.
final inherited
visualDensity
→ VisualDensity ?
Defines how compact the icon button's layout will be.
final inherited
Static Methods
styleFrom ({Color ? foregroundColor , Color ? backgroundColor , Color ? disabledForegroundColor , Color ? disabledBackgroundColor , Color ? focusColor , Color ? hoverColor , Color ? highlightColor , Color ? shadowColor , Color ? surfaceTintColor , double ? elevation , Size ? minimumSize , Size ? fixedSize , Size ? maximumSize , double ? iconSize , BorderSide ? side , OutlinedBorder ? shape , EdgeInsetsGeometry ? padding , MouseCursor ? enabledMouseCursor , MouseCursor ? disabledMouseCursor , VisualDensity ? visualDensity , MaterialTapTargetSize ? tapTargetSize , Duration ? animationDuration , bool ? enableFeedback , AlignmentGeometry ? alignment , InteractiveInkFeatureFactory ? splashFactory , Gradient ? backgroundGradient , Gradient ? foregroundGradient , Gradient ? borderGradient , PlatformStyle ? platformStyle , bool ? animateElevation })
→ CButtonStyle
A static convenience method that constructs an icon button
ButtonStyle given simple values. This method is only used for Material 3.
override