A button communicates an action that will occur when a user touches it.
Buttons are standard Android Open Source Project (AOSP) components. They can either be filled with a solid background color, or unfilled (with a transparent background). Filled buttons indicate a primary or preferred action. Buttons can appear independently or in groups – unlike tabs, which always appear in groups.
Anatomy
![Buttons anatomy](https://developers.google.cn/cars/design/automotive-os/components/images/buttons-anatomy-1.png?authuser=7)
2. Filled button container, indicating the primary or preferred action
3. Button label
Specs
Button min and max length
![Maximum button label length is 20 characters. Minimum button width is 156dp.](https://developers.google.cn/cars/design/automotive-os/components/images/buttons-spec-1.png?authuser=7)
Button with icon vs. default button
![Buttons can include icons. When included, icons typically appear to the left of button text.](https://developers.google.cn/cars/design/automotive-os/components/images/buttons-spec-3.png?authuser=7)
Buttons can appear as elements in other components, such as the app bar or dialogs.
Button placement in app bar
![Buttons are placed on the right side of the app bar](https://developers.google.cn/cars/design/automotive-os/components/images/buttons-spec-2.png?authuser=7)
Button in dialog
![Buttons in dialogs are typically located at the bottom left side of a dialog](https://developers.google.cn/cars/design/automotive-os/components/images/buttons-spec-4.png?authuser=7)
Hero button
![The rounded edges of a hero button emphasizw its importance](https://developers.google.cn/cars/design/automotive-os/components/images/buttons-spec-5.png?authuser=7)
Customization
OEMs can reflect their brand by modifying a button's visual appearance, such as:
- Specifying an accent color
- Supplying custom icons
- Adding custom fonts
- Changing the appearance of active, inactive, and disabled buttons
- Setting button dimensions, corner shape, and placements
- Using motion to provide feedback to users
The Car UI Library Integration Guide provides OEM guidance for customizing components.
Design system provides specific guidance for using layout, color, typography, sizing, shape, and motion to customize components.
Examples
![unfilled and filled buttons](https://developers.google.cn/cars/design/automotive-os/components/images/buttons-mock-1.png?authuser=7)
![disabled filled button](https://developers.google.cn/cars/design/automotive-os/components/images/buttons-mock-2.png?authuser=7)
![Unfilled button dialog](https://developers.google.cn/cars/design/automotive-os/components/images/buttons-mock-3.png?authuser=7)
![button ripple motion duration](https://developers.google.cn/cars/design/automotive-os/components/images/buttons-different-shapes.gif?authuser=7)
![Buttons ripple animation](https://developers.google.cn/cars/design/automotive-os/components/images/buttons-ripple.gif?authuser=7)