leticiars 8c6a164113 [Documentation] Fixing docs titles to be H1
PiperOrigin-RevId: 337308305
2020-10-15 13:39:33 -07:00

1.7 KiB

Time Pickers

Time Pickers allow users to select a single time.

Design

Material Design: Time Picker

Customization

A time picker can be instantiated by MaterialTimePicker.Builder.

The builder allows you to do the following:

  • Set the Time Format, 24 Hour clock or 12 Hour clock. Defaults to 12 Hour.
  • Set the starting time. Defaults to 12:00 am
  • Set the input mode to Keyboard or Clock. Defaults to Clock.

Examples of these customizations can be seen in the Time Picker Demo.

Demo

You can see the current version of the Time Picker Demo in the Material Android Catalog. The demo lets you choose between the different formats.

Code

The TimePicker Package contains the code for this component, with the main entry point being MaterialTimePicker.