| 302 | | (defun list-diary-entries (date number) |
|---|
| 303 | | "Create and display a buffer containing the relevant lines in diary-file. |
|---|
| | 295 | |
|---|
| | 296 | (defcustom number-of-diary-entries 1 |
|---|
| | 297 | "Specifies how many days of diary entries are to be displayed initially. |
|---|
| | 298 | This variable affects the diary display when the command \\[diary] is used, |
|---|
| | 299 | or if the value of the variable `view-diary-entries-initially' is t. For |
|---|
| | 300 | example, if the default value 1 is used, then only the current day's diary |
|---|
| | 301 | entries will be displayed. If the value 2 is used, then both the current |
|---|
| | 302 | day's and the next day's entries will be displayed. |
|---|
| | 303 | |
|---|
| | 304 | The value can also be a vector such as [0 2 2 2 2 4 1]; this value |
|---|
| | 305 | says to display no diary entries on Sunday, the display the entries |
|---|
| | 306 | for the current date and the day after on Monday through Thursday, |
|---|
| | 307 | display Friday through Monday's entries on Friday, and display only |
|---|
| | 308 | Saturday's entries on Saturday. |
|---|
| | 309 | |
|---|
| | 310 | This variable does not affect the diary display with the `d' command |
|---|
| | 311 | from the calendar; in that case, the prefix argument controls the |
|---|
| | 312 | number of days of diary entries displayed." |
|---|
| | 313 | :type '(choice (integer :tag "Entries") |
|---|
| | 314 | (vector :value [0 0 0 0 0 0 0] |
|---|
| | 315 | (integer :tag "Sunday") |
|---|
| | 316 | (integer :tag "Monday") |
|---|
| | 317 | (integer :tag "Tuesday") |
|---|
| | 318 | (integer :tag "Wednesday") |
|---|
| | 319 | (integer :tag "Thursday") |
|---|
| | 320 | (integer :tag "Friday") |
|---|
| | 321 | (integer :tag "Saturday"))) |
|---|
| | 322 | :group 'diary) |
|---|
| | 323 | |
|---|
| | 324 | (define-obsolete-function-alias 'list-diary-entries 'diary-list-entries) |
|---|
| | 325 | (defun diary-list-entries (date number) |
|---|
| | 326 | "Create and display a buffer containing the relevant lines in `diary-file'. |
|---|
| 359 | | (setq old-diary-syntax-table (syntax-table)) |
|---|
| 360 | | (set-syntax-table diary-syntax-table) |
|---|
| 361 | | (unwind-protect |
|---|
| 362 | | (let ((buffer-read-only nil) |
|---|
| 363 | | (diary-modified (buffer-modified-p)) |
|---|
| 364 | | (mark (regexp-quote diary-nonmarking-symbol))) |
|---|
| 365 | | ;; First and last characters must be ^M or \n for |
|---|
| 366 | | ;; selective display to work properly |
|---|
| 367 | | (goto-char (1- (point-max))) |
|---|
| 368 | | (if (not (looking-at "\^M\\|\n")) |
|---|
| 369 | | (progn |
|---|
| 370 | | (goto-char (point-max)) |
|---|
| 371 | | (insert "\^M"))) |
|---|
| 372 | | (goto-char (point-min)) |
|---|
| 373 | | (if (not (looking-at "\^M\\|\n")) |
|---|
| 374 | | (insert "\^M")) |
|---|
| 375 | | (subst-char-in-region (point-min) (point-max) ?\n ?\^M t) |
|---|
| 376 | | (calendar-for-loop |
|---|
| 377 | | i from 1 to number do |
|---|
| 378 | | (let ((d diary-date-forms) |
|---|
| 379 | | (month (extract-calendar-month date)) |
|---|
| 380 | | (day (extract-calendar-day date)) |
|---|
| 381 | | (year (extract-calendar-year date)) |
|---|
| 382 | | (entry-found (list-sexp-diary-entries date))) |
|---|
| 383 | | (while d |
|---|
| 384 | | (let* |
|---|
| 385 | | ((date-form (if (equal (car (car d)) 'backup) |
|---|
| 386 | | (cdr (car d)) |
|---|
| 387 | | (car d))) |
|---|
| 388 | | (backup (equal (car (car d)) 'backup)) |
|---|
| 389 | | (dayname |
|---|
| 390 | | (format "%s\\|%s\\.?" |
|---|
| 391 | | (calendar-day-name date) |
|---|
| 392 | | (calendar-day-name date 'abbrev))) |
|---|
| 393 | | (monthname |
|---|
| 394 | | (format "\\*\\|%s\\|%s\\.?" |
|---|
| 395 | | (calendar-month-name month) |
|---|
| 396 | | (calendar-month-name month 'abbrev))) |
|---|
| 397 | | (month (concat "\\*\\|0*" (int-to-string month))) |
|---|
| 398 | | (day (concat "\\*\\|0*" (int-to-string day))) |
|---|
| 399 | | (year |
|---|
| 400 | | (concat |
|---|
| 401 | | "\\*\\|0*" (int-to-string year) |
|---|
| 402 | | (if abbreviated-calendar-year |
|---|
| 403 | | (concat "\\|" (format "%02d" (% year 100))) |
|---|
| 404 | | ""))) |
|---|
| 405 | | (regexp |
|---|
| 406 | | (concat |
|---|
| 407 | | "\\(\\`\\|\^M\\|\n\\)" mark "?\\(" |
|---|
| 408 | | (mapconcat 'eval date-form "\\)\\(") |
|---|
| 409 | | "\\)")) |
|---|
| 410 | | (case-fold-search t)) |
|---|
| 411 | | (goto-char (point-min)) |
|---|
| 412 | | (while (re-search-forward regexp nil t) |
|---|
| 413 | | (if backup (re-search-backward "\\<" nil t)) |
|---|
| 414 | | (if (and (or (char-equal (preceding-char) ?\^M) |
|---|
| 415 | | (char-equal (preceding-char) ?\n)) |
|---|
| 416 | | (not (looking-at " \\|\^I"))) |
|---|
| 417 | | ;; Diary entry that consists only of date. |
|---|
| 418 | | (backward-char 1) |
|---|
| 419 | | ;; Found a nonempty diary entry--make it |
|---|
| 420 | | ;; visible and add it to the list. |
|---|
| 421 | | (setq entry-found t) |
|---|
| 422 | | (let ((entry-start (point)) |
|---|
| 423 | | date-start temp) |
|---|
| 424 | | (re-search-backward "\^M\\|\n\\|\\`") |
|---|
| 425 | | (setq date-start (point)) |
|---|
| 426 | | (re-search-forward "\^M\\|\n" nil t 2) |
|---|
| 427 | | (while (looking-at " \\|\^I") |
|---|
| 428 | | (re-search-forward "\^M\\|\n" nil t)) |
|---|
| 429 | | (backward-char 1) |
|---|
| 430 | | (subst-char-in-region date-start |
|---|
| 431 | | (point) ?\^M ?\n t) |
|---|
| 432 | | (setq entry (buffer-substring entry-start (point)) |
|---|
| 433 | | temp (diary-pull-attrs entry file-glob-attrs) |
|---|
| 434 | | entry (nth 0 temp)) |
|---|
| 435 | | (add-to-diary-list |
|---|
| 436 | | date |
|---|
| 437 | | entry |
|---|
| 438 | | (buffer-substring |
|---|
| 439 | | (1+ date-start) (1- entry-start)) |
|---|
| 440 | | (copy-marker entry-start) (nth 1 temp)))))) |
|---|
| 441 | | (setq d (cdr d))) |
|---|
| 442 | | (or entry-found |
|---|
| 443 | | (not diary-list-include-blanks) |
|---|
| 444 | | (setq diary-entries-list |
|---|
| 445 | | (append diary-entries-list |
|---|
| 446 | | (list (list date "" "" "" ""))))) |
|---|
| 447 | | (setq date |
|---|
| 448 | | (calendar-gregorian-from-absolute |
|---|
| 449 | | (1+ (calendar-absolute-from-gregorian date)))) |
|---|
| 450 | | (setq entry-found nil))) |
|---|
| 451 | | (set-buffer-modified-p diary-modified)) |
|---|
| 452 | | (set-syntax-table old-diary-syntax-table)) |
|---|
| | 384 | (with-syntax-table diary-syntax-table |
|---|
| | 385 | (let ((buffer-read-only nil) |
|---|
| | 386 | (diary-modified (buffer-modified-p)) |
|---|
| | 387 | (mark (regexp-quote diary-nonmarking-symbol))) |
|---|
| | 388 | ;; First and last characters must be ^M or \n for |
|---|
| | 389 | ;; selective display to work properly |
|---|
| | 390 | (goto-char (1- (point-max))) |
|---|
| | 391 | (if (not (looking-at "\^M\\|\n")) |
|---|
| | 392 | (progn |
|---|
| | 393 | (goto-char (point-max)) |
|---|
| | 394 | (insert "\^M"))) |
|---|
| | 395 | (goto-char (point-min)) |
|---|
| | 396 | (if (not (looking-at "\^M\\|\n")) |
|---|
| | 397 | (insert "\^M")) |
|---|
| | 398 | (subst-char-in-region (point-min) (point-max) ?\n ?\^M t) |
|---|
| | 399 | (calendar-for-loop |
|---|
| | 400 | i from 1 to number do |
|---|
| | 401 | (let ((month (extract-calendar-month date)) |
|---|
| | 402 | (day (extract-calendar-day date)) |
|---|
| | 403 | (year (extract-calendar-year date)) |
|---|
| | 404 | (entry-found (list-sexp-diary-entries date))) |
|---|
| | 405 | (dolist (date-form diary-date-forms) |
|---|
| | 406 | (let* |
|---|
| | 407 | ((backup (when (eq (car date-form) 'backup) |
|---|
| | 408 | (setq date-form (cdr date-form)) |
|---|
| | 409 | t)) |
|---|
| | 410 | (dayname |
|---|
| | 411 | (format "%s\\|%s\\.?" |
|---|
| | 412 | (calendar-day-name date) |
|---|
| | 413 | (calendar-day-name date 'abbrev))) |
|---|
| | 414 | (monthname |
|---|
| | 415 | (format "\\*\\|%s\\|%s\\.?" |
|---|
| | 416 | (calendar-month-name month) |
|---|
| | 417 | (calendar-month-name month 'abbrev))) |
|---|
| | 418 | (month (concat "\\*\\|0*" (int-to-string month))) |
|---|
| | 419 | (day (concat "\\*\\|0*" (int-to-string day))) |
|---|
| | 420 | (year |
|---|
| | 421 | (concat |
|---|
| | 422 | "\\*\\|0*" (int-to-string year) |
|---|
| | 423 | (if abbreviated-calendar-year |
|---|
| | 424 | (concat "\\|" (format "%02d" (% year 100))) |
|---|
| | 425 | ""))) |
|---|
| | 426 | (regexp |
|---|
| | 427 | (concat |
|---|
| | 428 | "\\(\\`\\|\^M\\|\n\\)" mark "?\\(" |
|---|
| | 429 | (mapconcat 'eval date-form "\\)\\(") |
|---|
| | 430 | "\\)")) |
|---|
| | 431 | (case-fold-search t)) |
|---|
| | 432 | (goto-char (point-min)) |
|---|
| | 433 | (while (re-search-forward regexp nil t) |
|---|
| | 434 | (if backup (re-search-backward "\\<" nil t)) |
|---|
| | 435 | (if (and (or (char-equal (preceding-char) ?\^M) |
|---|
| | 436 | (char-equal (preceding-char) ?\n)) |
|---|
| | 437 | (not (looking-at " \\|\^I"))) |
|---|
| | 438 | ;; Diary entry that consists only of date. |
|---|
| | 439 | (backward-char 1) |
|---|
| | 440 | ;; Found a nonempty diary entry--make it |
|---|
| | 441 | ;; visible and add it to the list. |
|---|
| | 442 | (setq entry-found t) |
|---|
| | 443 | (let ((entry-start (point)) |
|---|
| | 444 | date-start temp) |
|---|
| | 445 | (re-search-backward "\^M\\|\n\\|\\`") |
|---|
| | 446 | (setq date-start (point)) |
|---|
| | 447 | (re-search-forward "\^M\\|\n" nil t 2) |
|---|
| | 448 | (while (looking-at " \\|\^I") |
|---|
| | 449 | (re-search-forward "\^M\\|\n" nil t)) |
|---|
| | 450 | (backward-char 1) |
|---|
| | 451 | (subst-char-in-region date-start |
|---|
| | 452 | (point) ?\^M ?\n t) |
|---|
| | 453 | (setq entry (buffer-substring entry-start (point)) |
|---|
| | 454 | temp (diary-pull-attrs entry file-glob-attrs) |
|---|
| | 455 | entry (nth 0 temp)) |
|---|
| | 456 | (add-to-diary-list |
|---|
| | 457 | date |
|---|
| | 458 | entry |
|---|
| | 459 | (buffer-substring |
|---|
| | 460 | (1+ date-start) (1- entry-start)) |
|---|
| | 461 | (copy-marker entry-start) (nth 1 temp))))))) |
|---|
| | 462 | (or entry-found |
|---|
| | 463 | (not diary-list-include-blanks) |
|---|
| | 464 | (setq diary-entries-list |
|---|
| | 465 | (append diary-entries-list |
|---|
| | 466 | (list (list date "" "" "" ""))))) |
|---|
| | 467 | (setq date |
|---|
| | 468 | (calendar-gregorian-from-absolute |
|---|
| | 469 | (1+ (calendar-absolute-from-gregorian date)))) |
|---|
| | 470 | (setq entry-found nil))) |
|---|
| | 471 | (set-buffer-modified-p diary-modified))) |
|---|
| 861 | | (save-excursion |
|---|
| 862 | | (set-buffer (find-file-noselect (diary-check-diary-file) t)) |
|---|
| 863 | | (setq mark-diary-entries-in-calendar t) |
|---|
| 864 | | (message "Marking diary entries...") |
|---|
| 865 | | (setq file-glob-attrs (nth 1 (diary-pull-attrs nil '()))) |
|---|
| 866 | | (let ((d diary-date-forms) |
|---|
| 867 | | (old-diary-syntax-table (syntax-table)) |
|---|
| 868 | | temp) |
|---|
| 869 | | (set-syntax-table diary-syntax-table) |
|---|
| 870 | | (while d |
|---|
| 871 | | (let* ((date-form (if (equal (car (car d)) 'backup) |
|---|
| 872 | | (cdr (car d)) |
|---|
| 873 | | (car d)));; ignore 'backup directive |
|---|
| 874 | | (dayname |
|---|
| 875 | | (diary-name-pattern calendar-day-name-array |
|---|
| 876 | | calendar-day-abbrev-array)) |
|---|
| 877 | | (monthname |
|---|
| 878 | | (format "%s\\|\\*" |
|---|
| 879 | | (diary-name-pattern calendar-month-name-array |
|---|
| 880 | | calendar-month-abbrev-array))) |
|---|
| 881 | | (month "[0-9]+\\|\\*") |
|---|
| 882 | | (day "[0-9]+\\|\\*") |
|---|
| 883 | | (year "[0-9]+\\|\\*") |
|---|
| 884 | | (l (length date-form)) |
|---|
| 885 | | (d-name-pos (- l (length (memq 'dayname date-form)))) |
|---|
| 886 | | (d-name-pos (if (/= l d-name-pos) (+ 2 d-name-pos))) |
|---|
| 887 | | (m-name-pos (- l (length (memq 'monthname date-form)))) |
|---|
| 888 | | (m-name-pos (if (/= l m-name-pos) (+ 2 m-name-pos))) |
|---|
| 889 | | (d-pos (- l (length (memq 'day date-form)))) |
|---|
| 890 | | (d-pos (if (/= l d-pos) (+ 2 d-pos))) |
|---|
| 891 | | (m-pos (- l (length (memq 'month date-form)))) |
|---|
| 892 | | (m-pos (if (/= l m-pos) (+ 2 m-pos))) |
|---|
| 893 | | (y-pos (- l (length (memq 'year date-form)))) |
|---|
| 894 | | (y-pos (if (/= l y-pos) (+ 2 y-pos))) |
|---|
| 895 | | (regexp |
|---|
| 896 | | (concat |
|---|
| 897 | | "\\(\\`\\|\^M\\|\n\\)\\(" |
|---|
| 898 | | (mapconcat 'eval date-form "\\)\\(") |
|---|
| 899 | | "\\)")) |
|---|
| 900 | | (case-fold-search t)) |
|---|
| 901 | | (goto-char (point-min)) |
|---|
| 902 | | (while (re-search-forward regexp nil t) |
|---|
| 903 | | (let* ((dd-name |
|---|
| 904 | | (if d-name-pos |
|---|
| 905 | | (buffer-substring-no-properties |
|---|
| 906 | | (match-beginning d-name-pos) |
|---|
| 907 | | (match-end d-name-pos)))) |
|---|
| 908 | | (mm-name |
|---|
| 909 | | (if m-name-pos |
|---|
| 910 | | (buffer-substring-no-properties |
|---|
| 911 | | (match-beginning m-name-pos) |
|---|
| 912 | | (match-end m-name-pos)))) |
|---|
| 913 | | (mm (string-to-number |
|---|
| 914 | | (if m-pos |
|---|
| 915 | | (buffer-substring-no-properties |
|---|
| 916 | | (match-beginning m-pos) |
|---|
| 917 | | (match-end m-pos)) |
|---|
| 918 | | ""))) |
|---|
| 919 | | (dd (string-to-number |
|---|
| 920 | | (if d-pos |
|---|
| 921 | | (buffer-substring-no-properties |
|---|
| 922 | | (match-beginning d-pos) |
|---|
| 923 | | (match-end d-pos)) |
|---|
| 924 | | ""))) |
|---|
| 925 | | (y-str (if y-pos |
|---|
| 926 | | (buffer-substring-no-properties |
|---|
| 927 | | (match-beginning y-pos) |
|---|
| 928 | | (match-end y-pos)))) |
|---|
| 929 | | (yy (if (not y-str) |
|---|
| 930 | | 0 |
|---|
| 931 | | (if (and (= (length y-str) 2) |
|---|
| 932 | | abbreviated-calendar-year) |
|---|
| 933 | | (let* ((current-y |
|---|
| 934 | | (extract-calendar-year |
|---|
| 935 | | (calendar-current-date))) |
|---|
| 936 | | (y (+ (string-to-number y-str) |
|---|
| 937 | | (* 100 |
|---|
| 938 | | (/ current-y 100))))) |
|---|
| 939 | | (if (> (- y current-y) 50) |
|---|
| 940 | | (- y 100) |
|---|
| 941 | | (if (> (- current-y y) 50) |
|---|
| 942 | | (+ y 100) |
|---|
| 943 | | y))) |
|---|
| 944 | | (string-to-number y-str)))) |
|---|
| 945 | | (save-excursion |
|---|
| 946 | | (setq entry (buffer-substring-no-properties |
|---|
| 947 | | (point) (line-end-position)) |
|---|
| 948 | | temp (diary-pull-attrs entry file-glob-attrs) |
|---|
| 949 | | entry (nth 0 temp) |
|---|
| 950 | | marks (nth 1 temp)))) |
|---|
| 951 | | (if dd-name |
|---|
| 952 | | (mark-calendar-days-named |
|---|
| 953 | | (cdr (assoc-string |
|---|
| 954 | | dd-name |
|---|
| 955 | | (calendar-make-alist |
|---|
| 956 | | calendar-day-name-array |
|---|
| 957 | | 0 nil calendar-day-abbrev-array) t)) marks) |
|---|
| 958 | | (if mm-name |
|---|
| 959 | | (setq mm |
|---|
| 960 | | (if (string-equal mm-name "*") 0 |
|---|
| 961 | | (cdr (assoc-string |
|---|
| 962 | | mm-name |
|---|
| 963 | | (calendar-make-alist |
|---|
| 964 | | calendar-month-name-array |
|---|
| 965 | | 1 nil calendar-month-abbrev-array) t))))) |
|---|
| 966 | | (mark-calendar-date-pattern mm dd yy marks)))) |
|---|
| 967 | | (setq d (cdr d)))) |
|---|
| 968 | | (mark-sexp-diary-entries) |
|---|
| 969 | | (run-hooks 'nongregorian-diary-marking-hook |
|---|
| 970 | | 'mark-diary-entries-hook) |
|---|
| 971 | | (set-syntax-table old-diary-syntax-table) |
|---|
| | 867 | (with-current-buffer (find-file-noselect (diary-check-diary-file) t) |
|---|
| | 868 | (save-excursion |
|---|
| | 869 | (setq mark-diary-entries-in-calendar t) |
|---|
| | 870 | (message "Marking diary entries...") |
|---|
| | 871 | (setq file-glob-attrs (nth 1 (diary-pull-attrs nil '()))) |
|---|
| | 872 | (with-syntax-table diary-syntax-table |
|---|
| | 873 | (dolist (date-form diary-date-forms) |
|---|
| | 874 | (if (eq (car date-form) 'backup) |
|---|
| | 875 | (setq date-form (cdr date-form))) ;; ignore 'backup directive |
|---|
| | 876 | (let* ((dayname |
|---|
| | 877 | (diary-name-pattern calendar-day-name-array |
|---|
| | 878 | calendar-day-abbrev-array)) |
|---|
| | 879 | (monthname |
|---|
| | 880 | (format "%s\\|\\*" |
|---|
| | 881 | (diary-name-pattern calendar-month-name-array |
|---|
| | 882 | calendar-month-abbrev-array))) |
|---|
| | 883 | (month "[0-9]+\\|\\*") |
|---|
| | 884 | (day "[0-9]+\\|\\*") |
|---|
| | 885 | (year "[0-9]+\\|\\*") |
|---|
| | 886 | (l (length date-form)) |
|---|
| | 887 | (d-name-pos (- l (length (memq 'dayname date-form)))) |
|---|
| | 888 | (d-name-pos (if (/= l d-name-pos) (+ 2 d-name-pos))) |
|---|
| | 889 | (m-name-pos (- l (length (memq 'monthname date-form)))) |
|---|
| | 890 | (m-name-pos (if (/= l m-name-pos) (+ 2 m-name-pos))) |
|---|
| | 891 | (d-pos (- l (length (memq 'day date-form)))) |
|---|
| | 892 | (d-pos (if (/= l d-pos) (+ 2 d-pos))) |
|---|
| | 893 | (m-pos (- l (length (memq 'month date-form)))) |
|---|
| | 894 | (m-pos (if (/= l m-pos) (+ 2 m-pos))) |
|---|
| | 895 | (y-pos (- l (length (memq 'year date-form)))) |
|---|
| | 896 | (y-pos (if (/= l y-pos) (+ 2 y-pos))) |
|---|
| | 897 | (regexp |
|---|
| | 898 | (concat |
|---|
| | 899 | "\\(\\`\\|\^M\\|\n\\)\\(" |
|---|
| | 900 | (mapconcat 'eval date-form "\\)\\(") |
|---|
| | 901 | "\\)")) |
|---|
| | 902 | (case-fold-search t)) |
|---|
| | 903 | (goto-char (point-min)) |
|---|
| | 904 | (while (re-search-forward regexp nil t) |
|---|
| | 905 | (let* ((dd-name |
|---|
| | 906 | (if d-name-pos |
|---|
| | 907 | (match-string-no-properties d-name-pos))) |
|---|
| | 908 | (mm-name |
|---|
| | 909 | (if m-name-pos |
|---|
| | 910 | (match-string-no-properties m-name-pos))) |
|---|
| | 911 | (mm (string-to-number |
|---|
| | 912 | (if m-pos |
|---|
| | 913 | (match-string-no-properties m-pos) |
|---|
| | 914 | ""))) |
|---|
| | 915 | (dd (string-to-number |
|---|
| | 916 | (if d-pos |
|---|
| | 917 | (match-string-no-properties d-pos) |
|---|
| | 918 | ""))) |
|---|
| | 919 | (y-str (if y-pos |
|---|
| | 920 | (match-string-no-properties y-pos))) |
|---|
| | 921 | (yy (if (not y-str) |
|---|
| | 922 | 0 |
|---|
| | 923 | (if (and (= (length y-str) 2) |
|---|
| | 924 | abbreviated-calendar-year) |
|---|
| | 925 | (let* ((current-y |
|---|
| | 926 | (extract-calendar-year |
|---|
| | 927 | (calendar-current-date))) |
|---|
| | 928 | (y (+ (string-to-number y-str) |
|---|
| | 929 | (* 100 |
|---|
| | 930 | (/ current-y 100))))) |
|---|
| | 931 | (if (> (- y current-y) 50) |
|---|
| | 932 | (- y 100) |
|---|
| | 933 | (if (> (- current-y y) 50) |
|---|
| | 934 | (+ y 100) |
|---|
| | 935 | y))) |
|---|
| | 936 | (string-to-number y-str))))) |
|---|
| | 937 | (let ((tmp (diary-pull-attrs (buffer-substring-no-properties |
|---|
| | 938 | (point) (line-end-position)) |
|---|
| | 939 | file-glob-attrs))) |
|---|
| | 940 | (setq entry (nth 0 tmp) |
|---|
| | 941 | marks (nth 1 tmp))) |
|---|
| | 942 | (if dd-name |
|---|
| | 943 | (mark-calendar-days-named |
|---|
| | 944 | (cdr (assoc-string |
|---|
| | 945 | dd-name |
|---|
| | 946 | (calendar-make-alist |
|---|
| | 947 | calendar-day-name-array |
|---|
| | 948 | 0 nil calendar-day-abbrev-array) t)) marks) |
|---|
| | 949 | (if mm-name |
|---|
| | 950 | (setq mm |
|---|
| | 951 | (if (string-equal mm-name "*") 0 |
|---|
| | 952 | (cdr (assoc-string |
|---|
| | 953 | mm-name |
|---|
| | 954 | (calendar-make-alist |
|---|
| | 955 | calendar-month-name-array |
|---|
| | 956 | 1 nil calendar-month-abbrev-array) t))))) |
|---|
| | 957 | (mark-calendar-date-pattern mm dd yy marks)))))) |
|---|
| | 958 | (mark-sexp-diary-entries) |
|---|
| | 959 | (run-hooks 'nongregorian-diary-marking-hook |
|---|
| | 960 | 'mark-diary-entries-hook)) |
|---|