I am unable to change the selector color and other parts of the TimePicker. So far, I can change header color and background but I am unable to change the innercircle and the textcolor.
Change custom theme link.
My code :
<TimePicker
android:id="@+id/tp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:timePickerMode="clock"
android:headerBackground="#565466"
android:amPmBackgroundColor="#500126"
android:numbersBackgroundColor="#57e326"
android:numbersTextColor="#995394"
android:numbersSelectorColor="#675543"
android:textColorSecondary="#897530"
android:textColorPrimary="#359875"
/>
TimePicker material style:
TimePickerDialog material style with custom colors
<style name="MyTimePickerDialogStyle" parent="@style/ThemeOverlay.AppCompat.Dialog.Alert">
<item name="showTitle">false</item>
<item name="colorControlActivated">#ffd600</item>
<item name="colorAccent">#b71c1c</item>
<item name="android:textColorPrimary">#43a047</item>
<item name="android:textColorSecondary">#f44336</item>
</style>
TimePicker widget style
<style name="MyTimePickerWidgetStyle" parent="@android:style/Widget.Material.TimePicker">
<item name="android:headerBackground">#ffe082</item>
<item name="android:numbersTextColor">#b71c1c</item>
<item name="android:numbersInnerTextColor">#f44336</item>
<item name="android:numbersSelectorColor">#33691e</item>
<item name="android:numbersBackgroundColor">#ef9a9a</item>
<item name="android:amPmTextColor">#9c27b0</item>
</style>
For more information on TimePicker see http://www.zoftino.com/android-timepicker-example
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With