emacs-devel
[Top][All Lists]

## auto-coding-function for LaTeX

 From: Arne Jørgensen Subject: auto-coding-function for LaTeX Date: Tue, 09 Nov 2004 21:41:18 +0100 User-agent: Gnus/5.110003 (No Gnus v0.3) Emacs/21.3.50 (gnu/linux)

```Hello,

I have written a function (latex-auto-coding-function) that determines
a LaTeX files encoding from i.e. a

\usepackage[latin1]{inputenc}

line (if it is used).

It uses an alist for mapping the LaTeX input encoding names to Emacs'
coding system names. The entries in the alist that I have commented
out are those standard input encoding names in LaTeX that there are no
emacs codings for (or those that I could not identify the coding
system of).

If you find it useful it can be added to Emacs (the papers I signed
say "emacs gnus" - I don't whether that is for emacs AND gnus or just
for gnus).

I'm not a trained elisp programmer so feel free to comment on or
change the code.

If included it should probably be added to mule.el. I'm don't know
whether the latex-auto-coding-function should be added to
auto-coding-functions by default (sooner or later there will be a lot
of functions in there). I know it should be in my
auto-coding-functions though :-)

Kind regards,
--
Arne Jørgensen
Gammel Kongevej 7, 1. th., DK-1610 Copenhagen V, Denmark
mobile: +45 21 65 01 13