trailingDatesTextStyle property
The text style for the text in the trailing dates cell of SfCalendar month view.
Defaults to null.
Using a SfCalendarTheme
gives more fine-grained control over the
appearance of various components of the calendar.
See also:
- textStyle, which used to customize the text style for the text in month cell of calendar.
- leadingDatesTextStyle, which used to customize the text style for the leading dates text in month cell of month view.
- SfCalendar.todayTextStyle, which used to customize the text style for the today text cell in the month view of calendar.
- trailingDatesBackgroundColor, which fills the background of the trailing dates cells of month view in calendar.
- Knowledge base: How to style the month cell
- Knowledge base: How to customize the month cell with appointment count
- Knowledge base: How to customize the month cell based on the appointment using builder
- Knowledge base: How to customize the leading and trailing dates
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,
monthCellStyle
: MonthCellStyle(textStyle: TextStyle(fontStyle: FontStyle.
normal, fontSize: 15, color: Colors.black),
trailingDatesTextStyle: TextStyle(
fontStyle: FontStyle.normal,
fontSize: 15,
color: Colors.black),
leadingDatesTextStyle: TextStyle(
fontStyle: FontStyle.normal,
fontSize: 15,
color: Colors.black),
backgroundColor: Colors.red,
todayBackgroundColor: Colors.blue,
leadingDatesBackgroundColor: Colors.grey,
trailingDatesBackgroundColor: Colors.grey)),
),
);
}
Implementation
final TextStyle? trailingDatesTextStyle;