Next: Included Diary Files, Previous: Hebrew/Islamic Entries, Up: Calendar Customization [Contents][Index]
Diary display works by preparing the diary buffer and then running the
hook diary-display-hook
. The default value of this hook
(simple-diary-display
) hides the irrelevant diary entries and
then displays the buffer. However, if you specify the hook as follows,
(add-hook 'diary-display-hook 'fancy-diary-display)
this enables fancy diary display. It displays diary entries and holidays by copying them into a special buffer that exists only for the sake of display. Copying to a separate buffer provides an opportunity to change the displayed text to make it prettier—for example, to sort the entries by the dates they apply to.
As with simple diary display, you can print a hard copy of the buffer
with print-diary-entries
. To print a hard copy of a day-by-day
diary for a week by positioning point on Sunday of that week, type
7 d and then do M-x print-diary-entries. As usual, the
inclusion of the holidays slows down the display slightly; you can speed
things up by setting the variable holidays-in-diary-buffer
to
nil
.
Ordinarily, the fancy diary buffer does not show days for which there are
no diary entries, even if that day is a holiday. If you want such days to be
shown in the fancy diary buffer, set the variable
diary-list-include-blanks
to t
.
If you use the fancy diary display, you can use the normal hook
list-diary-entries-hook
to sort each day’s diary entries by their
time of day. Add this line to your init file:
(add-hook 'list-diary-entries-hook 'sort-diary-entries t)
See Init File.
For each day, this sorts diary entries that begin with a recognizable time of day according to their times. Diary entries without times come first within each day.
Next: Included Diary Files, Previous: Hebrew/Islamic Entries, Up: Calendar Customization [Contents][Index]