Function: cal-tex-cursor-filofax-year

cal-tex-cursor-filofax-year is an autoloaded, interactive and byte-compiled function defined in cal-tex.el.gz.

Signature

(cal-tex-cursor-filofax-year &optional N EVENT)

Documentation

Make a Filofax one page yearly calendar of year indicated by cursor.

Optional prefix argument N specifies number of years. Optional EVENT indicates a buffer position to use instead of point.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/calendar/cal-tex.el.gz
;;;###cal-autoload
(defun cal-tex-cursor-filofax-year (&optional n event)
  "Make a Filofax one page yearly calendar of year indicated by cursor.
Optional prefix argument N specifies number of years.
Optional EVENT indicates a buffer position to use instead of point."
  (interactive (list (prefix-numeric-value current-prefix-arg)
                     last-nonmenu-event))
  (or n (setq n 1))
  (let ((year (calendar-extract-year (calendar-cursor-to-date t event))))
    (cal-tex-preamble "twoside")
    (cal-tex-filofax-paper 'year)
    (cal-tex-cmd "\\fboxsep 0.5mm")
    (cal-tex-cmd "\\pagestyle" "empty")
    (cal-tex-b-document)
    (cal-tex-vspace "0.25in")
    (dotimes (j n)
      (insert (format "\\hfil \\textbf{\\Large %s} \\hfil\\\\\n" year))
      (cal-tex-b-center)
      (cal-tex-b-parbox "l" "\\textwidth")
      (insert "\n")
      (cal-tex-noindent)
      (cal-tex-nl)
      (let ((month-names; don't use default in case user changed it
             ;; These are only used to define the command names, not
             ;; the names of the months they insert.
             ["January" "February" "March" "April" "May" "June"
              "July" "August" "September" "October" "November" "December"]))
        (dotimes (i 12)
          (insert (cal-tex-mini-calendar (1+ i) year (aref month-names i)
                                         "1in" ".9in" "tiny" "0.6mm"))))
      (insert
       "\\noindent\\fbox{\\January}\\fbox{\\February}\\fbox{\\March}\\\\
\\noindent\\fbox{\\April}\\fbox{\\May}\\fbox{\\June}\\\\
\\noindent\\fbox{\\July}\\fbox{\\August}\\fbox{\\September}\\\\
\\noindent\\fbox{\\October}\\fbox{\\November}\\fbox{\\December}
")
      (cal-tex-e-parbox)
      (cal-tex-e-center)
      (setq year (1+ year))
      (if (= j (1- n))
          (cal-tex-end-document)
        (cal-tex-newpage)
        (cal-tex-vspace "0.25in"))
      (run-hooks 'cal-tex-year-hook))
    (run-hooks 'cal-tex-hook)))