Day Name Localization Format Issue

In SfDateRangePicker in Flutter, When we are showing Norwegian Language as an App Locale, day names are showing like MAN., TIR. ONS., but I want to format this to only single word like M, T, O. I applied dayFormat also on it as "EE", but it did change the day format in English to M, T, W but in Norwegian it is still same as MAN., TIR. here is the code.

monthViewSettings: DateRangePickerMonthViewSettings(
firstDayOfWeek: 1,
viewHeaderStyle: DateRangePickerViewHeaderStyle(
textStyle: AppFonts.centuryGothic(
context: context,
color: AppColors.paragraphTextColor,
),
),
dayFormat: 'EE',
showWeekNumber: false,
enableSwipeSelection: false,
blackoutDates: widget.bookedDates,
),

and here is the picture


1 Reply

IR Indumathi Ravichandran Syncfusion Team May 18, 2023 11:16 AM UTC

Hi Muhammad,


As per the shared information, we have checked and your requirement is “Customize the day format in the view header by the provided language of the Flutter Calendar”. By hiding the default headers (headerHeight and viewHeaderHeight value as 0) and adding the custom headers you can localize the headers with the required number of strings. We have prepared a simple sample for the same. Please find the sample from the following link.


We hope that this helps you. Please let us know if you need further assistance.


Regards,

Indumathi R


Attachment: viewheader_locale_bc3bb994.zip

Loader.
Up arrow icon