Enum TextButtonStyle

  • TextButtonStyle is an enum used to specify the style for TextButton.

  • Available styles include OUTLINED (default), FILLED, FILLED_TONAL, and BORDERLESS.

  • The TEXT property is deprecated and should not be used.

  • You can set the background color for FILLED buttons usingTextButton.setBackgroundColor().

  • Enums are called using their parent class, name, and property, such asCardService.TextButtonStyle.OUTLINED.

TextButtonStyle

An enum that specifies the style forTextButton.

OUTLINED is the default; it renders a simple text button with clear background.FILLED buttons have a background color you can set withTextButton.setBackgroundColor(backgroundColor).

To call an enum, you call its parent class, name, and property. For example,CardService.TextButtonStyle.OUTLINED.

Properties

PropertyTypeDescription
OUTLINEDEnumNormal text button with clear background. Default.
TEXTEnumDO NOT USE. Deprecated version of OUTLINED. Do not remove the field until it is confirmed notbeing used by any apps.
FILLEDEnumText button with colored background.
FILLED_TONALEnumNormal text button with an alternative middle ground between filled and outlined buttons.
BORDERLESSEnumNormal text button with no border.

Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025-12-03 UTC.