IconButton constructor

const IconButton({
  1. Key? key,
  2. required Widget icon,
  3. ButtonVariance variance = ButtonVariance.ghost,
  4. VoidCallback? onPressed,
  5. bool? enabled,
  6. Widget? leading,
  7. Widget? trailing,
  8. AlignmentGeometry? alignment,
  9. ButtonSize size = ButtonSize.normal,
  10. ButtonDensity density = ButtonDensity.icon,
  11. ButtonShape shape = ButtonShape.rectangle,
  12. FocusNode? focusNode,
  13. bool disableTransition = false,
  14. ValueChanged<bool>? onHover,
  15. ValueChanged<bool>? onFocus,
  16. bool trailingExpanded = false,
  17. bool? enableFeedback,
  18. GestureTapDownCallback? onTapDown,
  19. GestureTapUpCallback? onTapUp,
  20. GestureTapCancelCallback? onTapCancel,
  21. GestureTapDownCallback? onSecondaryTapDown,
  22. GestureTapUpCallback? onSecondaryTapUp,
  23. GestureTapCancelCallback? onSecondaryTapCancel,
  24. GestureTapDownCallback? onTertiaryTapDown,
  25. GestureTapUpCallback? onTertiaryTapUp,
  26. GestureTapCancelCallback? onTertiaryTapCancel,
  27. GestureLongPressStartCallback? onLongPressStart,
  28. GestureLongPressUpCallback? onLongPressUp,
  29. GestureLongPressMoveUpdateCallback? onLongPressMoveUpdate,
  30. GestureLongPressEndCallback? onLongPressEnd,
  31. GestureLongPressUpCallback? onSecondaryLongPress,
  32. GestureLongPressUpCallback? onTertiaryLongPress,
})

Implementation

const IconButton({
  super.key,
  required this.icon,
  this.variance = ButtonVariance.ghost,
  this.onPressed,
  this.enabled,
  this.leading,
  this.trailing,
  this.alignment,
  this.size = ButtonSize.normal,
  this.density = ButtonDensity.icon,
  this.shape = ButtonShape.rectangle,
  this.focusNode,
  this.disableTransition = false,
  this.onHover,
  this.onFocus,
  this.trailingExpanded = false,
  this.enableFeedback,
  this.onTapDown,
  this.onTapUp,
  this.onTapCancel,
  this.onSecondaryTapDown,
  this.onSecondaryTapUp,
  this.onSecondaryTapCancel,
  this.onTertiaryTapDown,
  this.onTertiaryTapUp,
  this.onTertiaryTapCancel,
  this.onLongPressStart,
  this.onLongPressUp,
  this.onLongPressMoveUpdate,
  this.onLongPressEnd,
  this.onSecondaryLongPress,
  this.onTertiaryLongPress,
});