TButtonGroup constructor

const TButtonGroup({
  1. Key? key,
  2. TButtonGroupTheme? theme,
  3. TButtonGroupType? type,
  4. Color? color,
  5. TButtonSize? size,
  6. List<TButtonGroupItem> items = const [],
  7. WrapAlignment alignment = WrapAlignment.start,
  8. bool cycle = false,
  9. int? initialIndex,
  10. ValueChanged<int>? onIndexChanged,
  11. bool separated = false,
  12. double? spacing,
  13. bool? showTick,
  14. Alignment? tickAlignment,
  15. Widget? tickWidget,
  16. bool expanded = false,
  17. String? label,
  18. String? tag,
  19. bool isRequired = false,
  20. String? helperText,
  21. String? info,
})

Creates a button group.

Implementation

const TButtonGroup({
  super.key,
  this.theme,
  this.type,
  this.color,
  this.size,
  this.items = const [],
  this.alignment = WrapAlignment.start,
  this.cycle = false,
  this.initialIndex,
  this.onIndexChanged,
  this.separated = false,
  this.spacing,
  this.showTick,
  this.tickAlignment,
  this.tickWidget,
  this.expanded = false,
  this.label,
  this.tag,
  this.isRequired = false,
  this.helperText,
  this.info,
}) : assert(
        theme == null || (type == null && size == null && color == null),
        'If theme is provided, type, color and size must be null.',
      );