androidx.compose.material3
ButtonGroupDefaultsSince 1.10
Object
No hand-written docs yet.
Default values used by ButtonGroup
object ButtonGroupDefaults
Properties
ExpandedRatio
val ExpandedRatio: Float
The default percentage, represented as a float, of the width of the interacted child element that will be used to expand the interacted child element as well as compress the neighboring children. By Default, standard button group will expand the interacted child element by 15% of its width and this will be propagated to its neighbors.
HorizontalArrangement
val HorizontalArrangement: Arrangement.Horizontal
The default Arrangement used between children for standard button group.
ConnectedSpaceBetween
val ConnectedSpaceBetween: Dp
The default spacing used between children for connected button group
connectedLeadingButtonShape
@Composable val connectedLeadingButtonShape: Shape
Default shape for the leading button in a connected button group
connectedLeadingButtonPressShape
@Composable val connectedLeadingButtonPressShape: Shape
Default shape for the pressed state for the leading button in a connected button group.
connectedTrailingButtonShape
@Composable val connectedTrailingButtonShape: Shape
Default shape for the trailing button in a connected button group
connectedTrailingButtonPressShape
@Composable val connectedTrailingButtonPressShape: Shape
Default shape for the pressed state for the trailing button in a connected button group.
connectedButtonCheckedShape
val connectedButtonCheckedShape: RoundedCornerShape
Default shape for the checked state for the buttons in a connected button group
connectedMiddleButtonPressShape
@Composable val connectedMiddleButtonPressShape: Shape
Default shape for the pressed state for the middle buttons in a connected button group.
Functions
connectedLeadingButtonShapes
@Composable
fun connectedLeadingButtonShapes(
shape: Shape = connectedLeadingButtonShape,
pressedShape: Shape = connectedLeadingButtonPressShape,
checkedShape: Shape = connectedButtonCheckedShape,
): ToggleButtonShapes
Defaults button shapes for the start button in a ConnectedButtonGroup
connectedMiddleButtonShapes
@Composable
fun connectedMiddleButtonShapes(
shape: Shape = ShapeDefaults.Small,
pressedShape: Shape = connectedMiddleButtonPressShape,
checkedShape: Shape = connectedButtonCheckedShape,
): ToggleButtonShapes
Defaults button shapes for a middle button in a ConnectedButtonGroup. A middle button is a button that's not the start / end button in the button group.
connectedTrailingButtonShapes
@Composable
fun connectedTrailingButtonShapes(
shape: Shape = connectedTrailingButtonShape,
pressedShape: Shape = connectedTrailingButtonPressShape,
checkedShape: Shape = connectedButtonCheckedShape,
): ToggleButtonShapes
Defaults button shapes for the end button in a ConnectedButtonGroup.
OverflowIndicator
@Composable
fun OverflowIndicator(
menuState: ButtonGroupMenuState,
modifier: Modifier = Modifier,
enabled: Boolean = true,
shape: Shape = IconButtonDefaults.filledShape,
colors: IconButtonColors = IconButtonDefaults.filledIconButtonColors(),
interactionSource: MutableInteractionSource? = null,
)
Default overflow indicator for ButtonGroup. It uses a FilledIconButton. When clicked it will open the menu associated with the provided ButtonGroupMenuState.
Library docs
Default values used by ButtonGroup