SegmentedControlContent constructor

const SegmentedControlContent({
  1. required List<GlassSegment> segments,
  2. required int selectedIndex,
  3. required ValueChanged<int> onSegmentSelected,
  4. required TextStyle? selectedTextStyle,
  5. required TextStyle? unselectedTextStyle,
  6. required Color? indicatorColor,
  7. required double borderRadius,
  8. required GlassQuality quality,
  9. Axis direction = Axis.horizontal,
  10. LiquidGlassSettings? indicatorSettings,
  11. double indicatorPinchStrength = 0.4,
  12. EdgeInsetsGeometry indicatorExpansion = const EdgeInsets.symmetric(horizontal: 12, vertical: 8),
  13. GlobalKey<State<StatefulWidget>>? backgroundKey,
  14. GlassInteractionBehavior interactionBehavior = GlassInteractionBehavior.full,
  15. Color? glowColor,
  16. double glowRadius = 1.5,
  17. Key? key,
})

Implementation

const SegmentedControlContent({
  required this.segments,
  required this.selectedIndex,
  required this.onSegmentSelected,
  required this.selectedTextStyle,
  required this.unselectedTextStyle,
  required this.indicatorColor,
  required this.borderRadius,
  required this.quality,
  this.direction = Axis.horizontal,
  this.indicatorSettings,
  this.indicatorPinchStrength = 0.4,
  this.indicatorExpansion =
      const EdgeInsets.symmetric(horizontal: 12, vertical: 8),
  this.backgroundKey,
  this.interactionBehavior = GlassInteractionBehavior.full,
  this.glowColor,
  this.glowRadius = 1.5,
  super.key,
});