monthViewSettings property
The settings have properties which allow to customize the month view of the SfCalendar.
Allows to customize the MonthViewSettings.dayFormat, MonthViewSettings.numberOfWeeksInView, MonthViewSettings.appointmentDisplayMode, MonthViewSettings.showAgenda, MonthViewSettings.appointmentDisplayCount, and MonthViewSettings.navigationDirection in month view of calendar.
See also:
- monthCellBuilder, to customize the month cell with custom widget in calendar.
- MonthViewSettings, to know more about the customization of month view in calendar.
- blackoutDates, which allows to restrict the interaction for a particular date in month views of calendar.
- blackoutDatesTextStyle, which used to customize the blackout dates text style in the month view of calendar.
- Knowledge base: How to customize agenda view height based on widget height
- Knowledge base: How to customize agenda item height
- Knowledge base: How to show appointment in agenda view using programmatic date selection
- Knowledge base: How to customize the blackout dates
- Knowledge base: How to customize the leading and trailing dates
- Knowledge base: How to style the month cell
- Knowledge base: How to change the number of weeks
- Knowledge base: How to customize the agenda view appointment
Widget build(BuildContext context) {
return Container(
child: SfCalendar(
view: CalendarView.month,
monthViewSettings: MonthViewSettings(
dayFormat: 'EEE',
numberOfWeeksInView: 4,
appointmentDisplayCount: 2,
appointmentDisplayMode: MonthAppointmentDisplayMode.appointment,
showAgenda: false,
navigationDirection: MonthNavigationDirection.horizontal),
),
);
}
Implementation
final MonthViewSettings monthViewSettings;