diff options
| -rw-r--r-- | doc/emacs/calendar.texi | 71 |
1 files changed, 36 insertions, 35 deletions
diff --git a/doc/emacs/calendar.texi b/doc/emacs/calendar.texi index 93671364a88..92f5c919414 100644 --- a/doc/emacs/calendar.texi +++ b/doc/emacs/calendar.texi | |||
| @@ -206,7 +206,7 @@ Move point to today's date (@code{calendar-goto-today}). | |||
| 206 | @kbd{g d} (@code{calendar-goto-date}) prompts for a year, a month, and a day | 206 | @kbd{g d} (@code{calendar-goto-date}) prompts for a year, a month, and a day |
| 207 | of the month, and then moves to that date. Because the calendar includes all | 207 | of the month, and then moves to that date. Because the calendar includes all |
| 208 | dates from the beginning of the current era, you must type the year in its | 208 | dates from the beginning of the current era, you must type the year in its |
| 209 | entirety; that is, type @samp{1990}, not @samp{90}. | 209 | entirety; that is, type @samp{2010}, not @samp{10}. |
| 210 | 210 | ||
| 211 | @kindex g D @r{(Calendar mode)} | 211 | @kindex g D @r{(Calendar mode)} |
| 212 | @findex calendar-goto-day-of-year | 212 | @findex calendar-goto-day-of-year |
| @@ -919,36 +919,11 @@ years, and then displays the list of yahrzeit dates. | |||
| 919 | 919 | ||
| 920 | The Emacs diary keeps track of appointments or other events on a daily | 920 | The Emacs diary keeps track of appointments or other events on a daily |
| 921 | basis, in conjunction with the calendar. To use the diary feature, you | 921 | basis, in conjunction with the calendar. To use the diary feature, you |
| 922 | must first create a @dfn{diary file} containing a list of events and | 922 | must first create a diary file containing a list of events and |
| 923 | their dates. Then Emacs can automatically pick out and display the | 923 | their dates. Then Emacs can automatically pick out and display the |
| 924 | events for today, for the immediate future, or for any specified | 924 | events for today, for the immediate future, or for any specified |
| 925 | date. | 925 | date. |
| 926 | 926 | ||
| 927 | The name of the diary file is specified by the variable | ||
| 928 | @code{diary-file}. The default is @file{~/.emacs.d/diary}, though for | ||
| 929 | compatibility with older versions Emacs will use @file{~/diary} if it | ||
| 930 | exists. Here's an example showing what the file looks like: | ||
| 931 | |||
| 932 | @example | ||
| 933 | 12/22/2012 Twentieth wedding anniversary!! | ||
| 934 | &1/1. Happy New Year! | ||
| 935 | 10/22 Ruth's birthday. | ||
| 936 | * 21, *: Payday | ||
| 937 | Tuesday--weekly meeting with grad students at 10am | ||
| 938 | Supowit, Shen, Bitner, and Kapoor to attend. | ||
| 939 | 1/13/89 Friday the thirteenth!! | ||
| 940 | &thu 4pm squash game with Lloyd. | ||
| 941 | mar 16 Dad's birthday | ||
| 942 | April 15, 2013 Income tax due. | ||
| 943 | &* 15 time cards due. | ||
| 944 | @end example | ||
| 945 | |||
| 946 | @noindent | ||
| 947 | This format is essentially the same as the one used by the separate | ||
| 948 | @command{calendar} utility that is present on some Unix systems. This | ||
| 949 | example uses extra spaces to align the event descriptions of most of | ||
| 950 | the entries. Such formatting is purely a matter of taste. | ||
| 951 | |||
| 952 | Although you probably will start by creating a diary manually, Emacs | 927 | Although you probably will start by creating a diary manually, Emacs |
| 953 | provides a number of commands to let you view, add, and change diary | 928 | provides a number of commands to let you view, add, and change diary |
| 954 | entries. | 929 | entries. |
| @@ -1069,10 +1044,18 @@ diary-mail-entries}. A prefix argument specifies how many days | |||
| 1069 | @vindex diary-file | 1044 | @vindex diary-file |
| 1070 | Your @dfn{diary file} is a file that records events associated with | 1045 | Your @dfn{diary file} is a file that records events associated with |
| 1071 | particular dates. The name of the diary file is specified by the | 1046 | particular dates. The name of the diary file is specified by the |
| 1072 | variable @code{diary-file}. The @code{calendar} utility program | 1047 | variable @code{diary-file}. The default is @file{~/.emacs.d/diary}, |
| 1073 | supports a subset of the format allowed by the Emacs diary facilities, | 1048 | though for compatibility with older versions Emacs will use |
| 1074 | so you can use that utility to view the diary file, with reasonable | 1049 | @file{~/diary} if it exists. |
| 1075 | results aside from the entries it cannot understand. | 1050 | @ignore |
| 1051 | @c I don't think this is relevant any more. The utility doesn't seem | ||
| 1052 | @c to be part of the default install on GNU/Linux machines these days. | ||
| 1053 | @c When I tried it with my basic diary file, it just died with an error. | ||
| 1054 | The @code{calendar} utility program supports a subset of the format | ||
| 1055 | allowed by the Emacs diary facilities, so you can use that utility to | ||
| 1056 | view the diary file, with reasonable results aside from the entries it | ||
| 1057 | cannot understand. | ||
| 1058 | @end ignore | ||
| 1076 | 1059 | ||
| 1077 | Each entry in the diary file describes one event and consists of one | 1060 | Each entry in the diary file describes one event and consists of one |
| 1078 | or more lines. An entry always begins with a date specification at the | 1061 | or more lines. An entry always begins with a date specification at the |
| @@ -1080,7 +1063,25 @@ left margin. The rest of the entry is simply text to describe the | |||
| 1080 | event. If the entry has more than one line, then the lines after the | 1063 | event. If the entry has more than one line, then the lines after the |
| 1081 | first must begin with whitespace to indicate they continue a previous | 1064 | first must begin with whitespace to indicate they continue a previous |
| 1082 | entry. Lines that do not begin with valid dates and do not continue a | 1065 | entry. Lines that do not begin with valid dates and do not continue a |
| 1083 | preceding entry are ignored. | 1066 | preceding entry are ignored. Here's an example: |
| 1067 | |||
| 1068 | @example | ||
| 1069 | 12/22/2015 Twentieth wedding anniversary! | ||
| 1070 | &1/1. Happy New Year! | ||
| 1071 | 10/22 Ruth's birthday. | ||
| 1072 | * 21, *: Payday | ||
| 1073 | Tuesday--weekly meeting with grad students at 10am | ||
| 1074 | Supowit, Shen, Bitner, and Kapoor to attend. | ||
| 1075 | 1/13/89 Friday the thirteenth!! | ||
| 1076 | &thu 4pm squash game with Lloyd. | ||
| 1077 | mar 16 Dad's birthday | ||
| 1078 | April 15, 2016 Income tax due. | ||
| 1079 | &* 15 time cards due. | ||
| 1080 | @end example | ||
| 1081 | |||
| 1082 | @noindent | ||
| 1083 | This example uses extra spaces to align the event descriptions of most | ||
| 1084 | of the entries. Such formatting is purely a matter of taste. | ||
| 1084 | 1085 | ||
| 1085 | You can also use a format where the first line of a diary entry | 1086 | You can also use a format where the first line of a diary entry |
| 1086 | consists only of the date or day name (with no following blanks or | 1087 | consists only of the date or day name (with no following blanks or |
| @@ -1271,12 +1272,12 @@ entry. The entry looks like this: | |||
| 1271 | 1272 | ||
| 1272 | @findex diary-anniversary | 1273 | @findex diary-anniversary |
| 1273 | @example | 1274 | @example |
| 1274 | %%(diary-anniversary 10 31 1948) Arthur's birthday | 1275 | %%(diary-anniversary 10 31 1988) Arthur's birthday |
| 1275 | @end example | 1276 | @end example |
| 1276 | 1277 | ||
| 1277 | @noindent | 1278 | @noindent |
| 1278 | This entry applies to October 31 in any year after 1948; @samp{10 31 | 1279 | This entry applies to October 31 in any year after 1988; @samp{10 31 |
| 1279 | 1948} specifies the date. (If you are using the European or ISO | 1280 | 1988} specifies the date. (If you are using the European or ISO |
| 1280 | calendar style, the input order of month, day and year is different.) | 1281 | calendar style, the input order of month, day and year is different.) |
| 1281 | The reason this expression requires a beginning year is that advanced | 1282 | The reason this expression requires a beginning year is that advanced |
| 1282 | diary functions can use it to calculate the number of elapsed years. | 1283 | diary functions can use it to calculate the number of elapsed years. |