Skip to content

Commit

Permalink
Document formatday and prepare
Browse files Browse the repository at this point in the history
  • Loading branch information
StanFromIreland authored Dec 4, 2024
1 parent 6bc3e83 commit fb2fee6
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions Doc/library/calendar.rst
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,19 @@ interpreted as prescribed by the ISO 8601 standard. Year 0 is 1 BC, year -1 is

:class:`TextCalendar` instances have the following methods:

.. method:: formatday(theday, weekday, width=2)

Return a string representing a single day formatted with the given width
which defaults to 2. If *theday* is ``0``, return a string of spaces of
the specified width, representing an empty day. The *weekday* parameter
represents the day of the week, where ``0`` is Monday and ``6`` is Sunday.

.. method:: formatweek()

.. method:: formatweekday()

.. method:: formatweekheader()

.. method:: formatmonth(theyear, themonth, w=0, l=0)

Return a month's calendar in a multi-line string. If *w* is provided, it
Expand All @@ -146,6 +159,7 @@ interpreted as prescribed by the ISO 8601 standard. Year 0 is 1 BC, year -1 is
on the first weekday as specified in the constructor or set by the
:meth:`setfirstweekday` method.

.. method:: formatmonthname()

.. method:: prmonth(theyear, themonth, w=0, l=0)

Expand Down

0 comments on commit fb2fee6

Please sign in to comment.