[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] /srv/bzr/emacs/trunk r103893: Small cal-tex fix.
From: |
Glenn Morris |
Subject: |
[Emacs-diffs] /srv/bzr/emacs/trunk r103893: Small cal-tex fix. |
Date: |
Tue, 12 Apr 2011 00:03:52 -0700 |
User-agent: |
Bazaar (2.3.1) |
------------------------------------------------------------
revno: 103893
committer: Glenn Morris <address@hidden>
branch nick: trunk
timestamp: Tue 2011-04-12 00:03:52 -0700
message:
Small cal-tex fix.
* lisp/calendar/cal-tex.el (cal-tex-end-document):
Try to automatically use latin1 input if needed.
modified:
lisp/ChangeLog
lisp/calendar/cal-tex.el
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog 2011-04-12 04:02:38 +0000
+++ b/lisp/ChangeLog 2011-04-12 07:03:52 +0000
@@ -1,5 +1,8 @@
2011-04-12 Glenn Morris <address@hidden>
+ * calendar/cal-tex.el (cal-tex-end-document):
+ Try to automatically use latin1 input if needed.
+
* calendar/cal-hebrew.el (diary-hebrew-rosh-hodesh):
Don't try to cons a mark onto an empty element.
=== modified file 'lisp/calendar/cal-tex.el'
--- a/lisp/calendar/cal-tex.el 2011-01-25 04:08:28 +0000
+++ b/lisp/calendar/cal-tex.el 2011-04-12 07:03:52 +0000
@@ -1587,6 +1587,16 @@
Insert the trailer to LaTeX document, pop to LaTeX buffer, add
informative header, and run HOOK."
(cal-tex-e-document)
+ (or (and cal-tex-preamble-extra
+ (string-match "inputenc" cal-tex-preamble-extra))
+ (not (re-search-backward "[^[:ascii:]]" nil 'move))
+ (progn
+ (goto-char (point-min))
+ (when (search-forward "documentclass" nil t)
+ (forward-line 1)
+ ;; Eg for some Bahai holidays.
+ ;; FIXME latin1 might not always be right.
+ (insert "\\usepackage[latin1]{inputenc}\n"))))
(latex-mode)
(pop-to-buffer cal-tex-buffer)
(goto-char (point-min))
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] /srv/bzr/emacs/trunk r103893: Small cal-tex fix.,
Glenn Morris <=