{% setvar book_path %}/reference/androidx/_book.yaml{% endsetvar %} {% include "_shared/_reference-head-tags.html" %}

RadioButtonDefaults

public static class RadioButtonDefaults


Defaults used in RadioButton.

Summary

Public fields

static @NonNull RadioButtonDefaults

Public methods

final @NonNull RadioButtonColors

Creates a RadioButtonColors that will animate between the provided colors according to the Material specification.

final @NonNull RadioButtonColors
@Composable
colors(
    @NonNull Color selectedColor,
    @NonNull Color unselectedColor,
    @NonNull Color disabledSelectedColor,
    @NonNull Color disabledUnselectedColor
)

Creates a RadioButtonColors that will animate between the provided colors according to the Material specification.

Public fields

INSTANCE

public static @NonNull RadioButtonDefaults INSTANCE

Public methods

colors

@Composable
public final @NonNull RadioButtonColors colors()

Creates a RadioButtonColors that will animate between the provided colors according to the Material specification.

colors

@Composable
public final @NonNull RadioButtonColors colors(
    @NonNull Color selectedColor,
    @NonNull Color unselectedColor,
    @NonNull Color disabledSelectedColor,
    @NonNull Color disabledUnselectedColor
)

Creates a RadioButtonColors that will animate between the provided colors according to the Material specification.

Parameters
@NonNull Color selectedColor

the color to use for the RadioButton when selected and enabled.

@NonNull Color unselectedColor

the color to use for the RadioButton when unselected and enabled.

@NonNull Color disabledSelectedColor

the color to use for the RadioButton when disabled and selected.

@NonNull Color disabledUnselectedColor

the color to use for the RadioButton when disabled and not selected.

Returns
@NonNull RadioButtonColors

the resulting RadioButtonColors used for the RadioButton