CalendarDatePicker2Config class

Custom configuration for CalendarDatePicker2

Constructors

CalendarDatePicker2Config({CalendarDatePicker2Type? calendarType, DateTime? firstDate, DateTime? lastDate, DateTime? currentDate, CalendarDatePicker2Mode? calendarViewMode, List<String>? weekdayLabels, TextStyle? weekdayLabelTextStyle, WeekdayLabelBuilder? weekdayLabelBuilder, int? firstDayOfWeek, double? controlsHeight, Widget? lastMonthIcon, bool? hideLastMonthIcon, Widget? nextMonthIcon, bool? hideNextMonthIcon, TextStyle? controlsTextStyle, bool? animateToDisplayedMonthDate, Map<CalendarDatePicker2SemanticsLabel, String?>? semanticsDictionary, bool? disableVibration, PageController? dayViewController, TextStyle? dayTextStyle, TextStyle? selectedDayTextStyle, Color? selectedDayHighlightColor, Color? selectedRangeHighlightColor, TextStyle? disabledDayTextStyle, TextStyle? todayTextStyle, TextStyle? yearTextStyle, TextStyle? selectedYearTextStyle, TextStyle? disabledYearTextStyle, TextStyle? monthTextStyle, TextStyle? selectedMonthTextStyle, TextStyle? disabledMonthTextStyle, BorderRadius? dayBorderRadius, BorderRadius? yearBorderRadius, BorderRadius? monthBorderRadius, SelectableDayPredicate? selectableDayPredicate, SelectableMonthPredicate? selectableMonthPredicate, SelectableYearPredicate? selectableYearPredicate, DayTextStylePredicate? dayTextStylePredicate, DayBuilder? dayBuilder, YearBuilder? yearBuilder, MonthBuilder? monthBuilder, ScrollController? monthViewController, ScrollController? yearViewController, bool? disableModePicker, bool? centerAlignModePicker, Widget? customModePickerIcon, ModePickerTextHandler? modePickerTextHandler, ModePickerBuilder? modePickerBuilder, double? modePickersGap, TextStyle? selectedRangeDayTextStyle, bool? rangeBidirectional, ScrollPhysics? calendarViewScrollPhysics, Color? daySplashColor, bool? allowSameValueSelection, bool? disableMonthPicker, bool? useAbbrLabelForMonthModePicker, double? dayMaxWidth, bool? hideMonthPickerDividers, bool? hideYearPickerDividers, TextStyle? scrollViewTopHeaderTextStyle, bool? hideScrollViewTopHeader, bool? hideScrollViewTopHeaderDivider, bool? hideScrollViewMonthWeekHeader, BoxConstraints? scrollViewConstraints, ScrollViewMonthYearBuilder? scrollViewMonthYearBuilder, ScrollViewOnScrolling? scrollViewOnScrolling, ScrollController? scrollViewController, bool? dynamicCalendarRows, Axis? dayModeScrollDirection, SelectedRangeHighlightBuilder? selectedRangeHighlightBuilder, SelectedRangeDecorationPredicate? selectedRangeDecorationPredicate})

Properties

allowSameValueSelection bool?
When set to true, onValueChanged will be called on the same value selection
final
animateToDisplayedMonthDate bool?
Flag to always animate to the displayedMonthDate
final
calendarType CalendarDatePicker2Type
The enabled date picker mode
final
calendarViewMode CalendarDatePicker2Mode
The initially displayed view of the calendar picker.
final
calendarViewScrollPhysics ScrollPhysics?
The scroll physics for the calendar month view
final
centerAlignModePicker bool?
Flag to centralize year and month text label in controls
final
controlsHeight double?
Custom height for calendar control toggle's height
final
controlsTextStyle TextStyle?
Custom text style for calendar mode toggle control
final
currentDate DateTime
The DateTime representing today. It will be highlighted in the day grid.
final
customModePickerIcon Widget?
Custom icon for the mode picker button icon
final
dayBorderRadius BorderRadius?
Custom border radius for day indicator
final
dayBuilder DayBuilder?
Function to provide full control over day widget UI
final
dayMaxWidth double?
Max width of day widget. When dayMaxWidth is not null, it will override default size settings
final
dayModeScrollDirection Axis?
Axis scroll direction for CalendarDatePicker2Mode.day mode
final
daySplashColor Color?
The splash color of the day widget
final
dayTextStyle TextStyle?
Custom text style for all calendar days
final
dayTextStylePredicate DayTextStylePredicate?
Function to provide full control over calendar days text style
final
dayViewController PageController?
Custom page controller for the calendar day view mode
final
disabledDayTextStyle TextStyle?
Custom text style for disabled calendar day(s)
final
disabledMonthTextStyle TextStyle?
Custom text style for disabled month(s)
final
disabledYearTextStyle TextStyle?
Custom text style for disabled year(s)
final
disableModePicker bool?
Flag to disable mode picker and hide the mode toggle button icon
final
disableMonthPicker bool?
Flag to disable month picker
final
disableVibration bool?
Flag to disable vibration on date selection
final
dynamicCalendarRows bool?
Flag to enable dynamic calendar rows based on specific month
final
firstDate DateTime
The earliest allowable DateTime that the user can select.
final
firstDayOfWeek int?
Index of the first day of week, where 0 points to Sunday, and 6 points to Saturday.
final
hashCode int
The hash code for this object.
no setterinherited
hideLastMonthIcon bool?
Flag to hide last month icon
final
hideMonthPickerDividers bool?
Flag to hide dividers on month picker
final
hideNextMonthIcon bool?
Flag to hide next month icon
final
hideScrollViewMonthWeekHeader bool?
Flag to hide month calendar week labels header on scroll view
final
hideScrollViewTopHeader bool?
Flag to hide top week labels header on scroll view
final
hideScrollViewTopHeaderDivider bool?
Flag to hide top week labels header divider on scroll view
final
hideYearPickerDividers bool?
Flag to hide dividers on year picker
final
lastDate DateTime
The latest allowable DateTime that the user can select.
final
lastMonthIcon Widget?
Custom icon for last month button control
final
modePickerBuilder ModePickerBuilder?
Function to provide full control over mode picker UI
final
modePickersGap double?
Custom gap distance between month and year mode pickers
final
modePickerTextHandler ModePickerTextHandler?
Function to control mode picker displayed text
final
monthBorderRadius BorderRadius?
Custom border radius for month indicator
final
monthBuilder MonthBuilder?
Function to provide full control over month widget UI
final
monthTextStyle TextStyle?
Custom text style for month list
final
monthViewController ScrollController?
Custom scroll controller for the calendar month view
final
nextMonthIcon Widget?
Custom icon for next month button control
final
rangeBidirectional bool?
Whether the range selection can be also made in reverse-chronological order. Only applicable when calendarType is CalendarDatePicker2Type.range.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
scrollViewConstraints BoxConstraints?
BoxConstraints for the scroll calendar view, only work for scroll mode
final
scrollViewController ScrollController?
Custom scroll controller to the scroll calendar view
final
scrollViewMonthYearBuilder ScrollViewMonthYearBuilder?
Function to provide full control over scroll calendar month year UI
final
scrollViewOnScrolling ScrollViewOnScrolling?
Function to callback over scrolling on scroll view
final
scrollViewTopHeaderTextStyle TextStyle?
Custom text style for scroll view top week labels header
final
selectableDayPredicate SelectableDayPredicate?
Function to provide full control over which dates in the calendar can be selected.
final
selectableMonthPredicate SelectableMonthPredicate?
Function to provide full control over which month in the month list can be selected.
final
selectableYearPredicate SelectableYearPredicate?
Function to provide full control over which year in the year list be selected.
final
selectedDayHighlightColor Color?
The highlight color for selected day(s)
final
selectedDayTextStyle TextStyle?
Custom text style for selected calendar day(s)
final
selectedMonthTextStyle TextStyle?
Custom text style for selected month(s)
final
selectedRangeDayTextStyle TextStyle?
Custom text style for selected range calendar day(s)
final
selectedRangeDecorationPredicate SelectedRangeDecorationPredicate?
Predicate to determine the day widget box decoration for a day in selected range
final
selectedRangeHighlightBuilder SelectedRangeHighlightBuilder?
Function to provide full control over range picker highlight
final
selectedRangeHighlightColor Color?
The highlight color for day(s) included in the selected range Only applicable when calendarType is CalendarDatePicker2Type.range
final
selectedYearTextStyle TextStyle?
Custom text style for selected year(s)
final
semanticsDictionary Map<CalendarDatePicker2SemanticsLabel, String?>?
Custom dictionary for semantics labels
final
todayTextStyle TextStyle?
Custom text style for today
final
useAbbrLabelForMonthModePicker bool?
Use Abbreviation label for month mode picker, only works when month picker is enabled
final
weekdayLabelBuilder WeekdayLabelBuilder?
Function to provide full control over weekday label widget
final
weekdayLabels List<String>?
Custom weekday labels for the current locale, MUST starts from Sunday Examples:
final
weekdayLabelTextStyle TextStyle?
Custom text style for weekday labels
final
yearBorderRadius BorderRadius?
Custom border radius for year indicator
final
yearBuilder YearBuilder?
Function to provide full control over year widget UI
final
yearTextStyle TextStyle?
Custom text style for years list
final
yearViewController ScrollController?
Custom scroll controller for the calendar year view
final

Methods

copyWith({CalendarDatePicker2Type? calendarType, DateTime? firstDate, DateTime? lastDate, DateTime? currentDate, CalendarDatePicker2Mode? calendarViewMode, List<String>? weekdayLabels, TextStyle? weekdayLabelTextStyle, WeekdayLabelBuilder? weekdayLabelBuilder, int? firstDayOfWeek, double? controlsHeight, Widget? lastMonthIcon, bool? hideLastMonthIcon, Widget? nextMonthIcon, bool? hideNextMonthIcon, TextStyle? controlsTextStyle, bool? animateToDisplayedMonthDate, Map<CalendarDatePicker2SemanticsLabel, String?>? semanticsDictionary, bool? disableVibration, PageController? dayViewController, TextStyle? dayTextStyle, TextStyle? selectedDayTextStyle, Color? selectedDayHighlightColor, Color? selectedRangeHighlightColor, TextStyle? disabledDayTextStyle, TextStyle? todayTextStyle, TextStyle? yearTextStyle, TextStyle? selectedYearTextStyle, TextStyle? disabledYearTextStyle, TextStyle? selectedRangeDayTextStyle, TextStyle? monthTextStyle, TextStyle? selectedMonthTextStyle, TextStyle? disabledMonthTextStyle, BorderRadius? dayBorderRadius, BorderRadius? yearBorderRadius, BorderRadius? monthBorderRadius, SelectableDayPredicate? selectableDayPredicate, SelectableMonthPredicate? selectableMonthPredicate, SelectableYearPredicate? selectableYearPredicate, DayTextStylePredicate? dayTextStylePredicate, DayBuilder? dayBuilder, YearBuilder? yearBuilder, MonthBuilder? monthBuilder, ScrollController? monthViewController, ScrollController? yearViewController, bool? disableModePicker, bool? centerAlignModePicker, Widget? customModePickerIcon, ModePickerTextHandler? modePickerTextHandler, ModePickerBuilder? modePickerBuilder, double? modePickersGap, bool? rangeBidirectional, ScrollPhysics? calendarViewScrollPhysics, Color? daySplashColor, bool? allowSameValueSelection, bool? disableMonthPicker, bool? useAbbrLabelForMonthModePicker, double? dayMaxWidth, bool? hideMonthPickerDividers, bool? hideYearPickerDividers, TextStyle? scrollViewTopHeaderTextStyle, bool? hideScrollViewTopHeader, bool? hideScrollViewTopHeaderDivider, bool? hideScrollViewMonthWeekHeader, BoxConstraints? scrollViewConstraints, ScrollViewMonthYearBuilder? scrollViewMonthYearBuilder, ScrollViewOnScrolling? scrollViewOnScrolling, ScrollController? scrollViewController, bool? dynamicCalendarRows, Axis? dayModeScrollDirection, SelectedRangeHighlightBuilder? selectedRangeHighlightBuilder, SelectedRangeDecorationPredicate? selectedRangeDecorationPredicate}) CalendarDatePicker2Config
Copy the current CalendarDatePicker2Config with some new values
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited