1 |
@c -*-texinfo-*- |
@c -*-texinfo-*- |
2 |
@c This is part of the GNU Emacs Lisp Reference Manual. |
@c This is part of the GNU Emacs Lisp Reference Manual. |
3 |
@c Copyright (C) 1990, 1991, 1992, 1993, 1995, 1998 Free Software Foundation, Inc. |
@c Copyright (C) 1990, 1991, 1992, 1993, 1995, 1998 Free Software Foundation, Inc. |
4 |
@c See the file elisp.texi for copying conditions. |
@c See the file elisp.texi for copying conditions. |
5 |
@node Calendar, System Interface, Display, Top |
@node Calendar, System Interface, Display, Top |
6 |
@chapter Customizing the Calendar and Diary |
@chapter Customizing the Calendar and Diary |
16 |
* Daylight Savings:: Changing the default. |
* Daylight Savings:: Changing the default. |
17 |
* Diary Customizing:: Defaults you can set. |
* Diary Customizing:: Defaults you can set. |
18 |
* Hebrew/Islamic Entries:: How to obtain them. |
* Hebrew/Islamic Entries:: How to obtain them. |
19 |
* Fancy Diary Display:: Enhancing the diary display, sorting entries, |
* Fancy Diary Display:: Enhancing the diary display, sorting entries, |
20 |
using included diary files. |
using included diary files. |
21 |
* Sexp Diary Entries:: Fancy things you can do. |
* Sexp Diary Entries:: Fancy things you can do. |
22 |
* Appt Customizing:: Customizing appointment reminders. |
* Appt Customizing:: Customizing appointment reminders. |
543 |
well as entries based on the world-standard Gregorian calendar. |
well as entries based on the world-standard Gregorian calendar. |
544 |
However, because recognition of such entries is time-consuming and most |
However, because recognition of such entries is time-consuming and most |
545 |
people don't use them, you must explicitly enable their use. If you |
people don't use them, you must explicitly enable their use. If you |
546 |
want the diary to recognize Hebrew-date diary entries, for example, |
want the diary to recognize Hebrew-date diary entries, for example, |
547 |
you must do this: |
you must do this: |
548 |
|
|
549 |
@vindex nongregorian-diary-listing-hook |
@vindex nongregorian-diary-listing-hook |
603 |
selected date. |
selected date. |
604 |
@item i h y |
@item i h y |
605 |
Add a diary entry for the day of the Hebrew year corresponding to the |
Add a diary entry for the day of the Hebrew year corresponding to the |
606 |
selected date (@code{insert-yearly-hebrew-diary-entry}). This diary |
selected date (@code{insert-yearly-hebrew-diary-entry}). This diary |
607 |
entry matches any date which has the same Hebrew month and day-within-month |
entry matches any date which has the same Hebrew month and day-within-month |
608 |
as the selected date. |
as the selected date. |
609 |
@item i i d |
@item i i d |
626 |
These commands work much like the corresponding commands for ordinary |
These commands work much like the corresponding commands for ordinary |
627 |
diary entries: they apply to the date that point is on in the calendar |
diary entries: they apply to the date that point is on in the calendar |
628 |
window, and what they do is insert just the date portion of a diary entry |
window, and what they do is insert just the date portion of a diary entry |
629 |
at the end of your diary file. You must then insert the rest of the |
at the end of your diary file. You must then insert the rest of the |
630 |
diary entry. |
diary entry. |
631 |
|
|
632 |
@node Fancy Diary Display |
@node Fancy Diary Display |
830 |
@noindent |
@noindent |
831 |
on the last Monday of every month. |
on the last Monday of every month. |
832 |
|
|
833 |
The generality of sexp diary entries lets you specify any diary entry |
The generality of sexp diary entries lets you specify any diary |
834 |
that you can describe algorithmically. A sexp diary entry contains an |
entry that you can describe algorithmically. A sexp diary entry |
835 |
expression that computes whether the entry applies to any given date. |
contains an expression that computes whether the entry applies to any |
836 |
If its value is non-@code{nil}, the entry applies to that date; |
given date. If its value is non-@code{nil}, the entry applies to that |
837 |
otherwise, it does not. The expression can use the variable @code{date} |
date; otherwise, it does not. The expression can use the variable |
838 |
to find the date being considered; its value is a list (@var{month} |
@code{date} to find the date being considered; its value is a list |
839 |
@var{day} @var{year}) that refers to the Gregorian calendar. |
(@var{month} @var{day} @var{year}) that refers to the Gregorian |
840 |
|
calendar. |
841 |
|
|
842 |
|
The sexp diary entry applies to a date when the expression's value |
843 |
|
is non-@code{nil}, but some values have more specific meanings. If |
844 |
|
the value is a string, that string is a description of the event which |
845 |
|
occurs on that date. The value can also have the form |
846 |
|
@code{(@var{mark} . @var{string})}; then @var{mark} specifies how to |
847 |
|
mark the date in the calendar, and @var{string} is the description of |
848 |
|
the event. If @var{mark} is a single-character string, that character |
849 |
|
appears next to the date in the calendar. If @var{mark} is a face |
850 |
|
name, the date is displayed in that face. If @var{mark} is |
851 |
|
@code{nil}, that specifies no particular highlighting for the date. |
852 |
|
|
853 |
Suppose you get paid on the 21st of the month if it is a weekday, and |
Suppose you get paid on the 21st of the month if it is a weekday, and |
854 |
on the Friday before if the 21st is on a weekend. Here is how to write |
on the Friday before if the 21st is on a weekend. Here is how to write |
945 |
@var{month}, @var{year}.) |
@var{month}, @var{year}.) |
946 |
@end table |
@end table |
947 |
|
|
948 |
|
All the functions documented above take an optional argument |
949 |
|
@var{mark} which specifies how to mark the date in the calendar display. |
950 |
|
If one of these functions decides that it applies to a certain date, |
951 |
|
it returns a value that contains @var{mark}. |
952 |
|
|
953 |
@node Appt Customizing |
@node Appt Customizing |
954 |
@section Customizing Appointment Reminders |
@section Customizing Appointment Reminders |
955 |
|
|