return super().formatmonthname(theyear, themonth, withyear)
-class _CLIDemoCalendar(LocaleTextCalendar):
+class _CLIDemoCalendar(TextCalendar):
def __init__(self, highlight_day=None, *args, **kwargs):
super().__init__(*args, **kwargs)
self.highlight_day = highlight_day
return ''.join(v)
+class _CLIDemoLocaleCalendar(LocaleTextCalendar, _CLIDemoCalendar):
+ def __init__(self, highlight_day=None, *args, **kwargs):
+ super().__init__(*args, **kwargs)
+ self.highlight_day = highlight_day
+
+
# Support for old module level interface
c = TextCalendar()
write(cal.formatyearpage(options.year, **optdict))
else:
if options.locale:
- cal = _CLIDemoCalendar(highlight_day=today, locale=locale)
+ cal = _CLIDemoLocaleCalendar(highlight_day=today, locale=locale)
else:
cal = _CLIDemoCalendar(highlight_day=today)
cal.setfirstweekday(options.first_weekday)