getTextColor

open fun getTextColor(@NonNull context: Context, year: Int, month: Int, day: Int, valid: Boolean, selected: Boolean): ColorStateList

Override this method to return a custom color to be applied to the text of the day view corresponding to the provided date.

Return

The text color ColorStateList or null

Parameters

context

The context of the day view

year

The year number corresponding to the day view (see java.util.Calendar.YEAR)

month

The month number (0-11) corresponding to the day view (see )

day

The day of month number corresponding to the day view (see )

valid

Boolean for whether the day view is in a valid state (if not valid, the day view will likely look and behave disabled)

selected

Boolean for whether the day view is in a selected state (if selected, the day view will likely have a filled color background)