2012-08-21 Glenn Morris <rgm@gnu.org>
+ * calendar/cal-tex.el (cal-tex-preamble): Generate new buffers.
+ (cal-tex-end-document): Don't rely on buffer name.
+
* calendar/cal-tex.el (cal-tex-cursor-filofax-year):
Use cal-tex-vspace.
(cal-tex-vspace, cal-tex-hspace, cal-tex-em, cal-tex-bf)
"Insert the LaTeX calendar preamble into `cal-tex-buffer'.
Preamble includes initial definitions for various LaTeX commands.
Optional string ARGS are included as options for the article document class."
- ;; FIXME use generate-new-buffer, and adjust cal-tex-end-document.
- (set-buffer (get-buffer-create cal-tex-buffer))
+ (set-buffer (generate-new-buffer cal-tex-buffer))
(insert (format "\\documentclass%s{article}\n"
(if (stringp args)
(format "[%s]" args)
;; FIXME latin1 might not always be right.
(insert "\\usepackage[latin1]{inputenc}\n"))))
(latex-mode)
- (pop-to-buffer cal-tex-buffer)
+ (pop-to-buffer (current-buffer))
(goto-char (point-min))
;; FIXME auctex equivalents?
(cal-tex-comment