FilledButton.icon constructor

FilledButton.icon(
  1. {Key? key,
  2. required VoidCallback? onPressed,
  3. VoidCallback? onLongPress,
  4. ValueChanged<bool>? onHover,
  5. ValueChanged<bool>? onFocusChange,
  6. ButtonStyle? style,
  7. FocusNode? focusNode,
  8. bool? autofocus,
  9. Clip? clipBehavior,
  10. MaterialStatesController? statesController,
  11. required Widget icon,
  12. required Widget label}
)

Create a filled button from icon and label.

The icon and label are arranged in a row with padding at the start and end and a gap between them.

Implementation

factory FilledButton.icon({
  Key? key,
  required VoidCallback? onPressed,
  VoidCallback? onLongPress,
  ValueChanged<bool>? onHover,
  ValueChanged<bool>? onFocusChange,
  ButtonStyle? style,
  FocusNode? focusNode,
  bool? autofocus,
  Clip? clipBehavior,
  MaterialStatesController? statesController,
  required Widget icon,
  required Widget label,
}) = _FilledButtonWithIcon;