[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[AUCTeX] Adding new environments with label support

From: address@hidden
Subject: [AUCTeX] Adding new environments with label support
Date: Thu, 24 Jan 2013 20:27:45 -0600


I added a new environment as follows in my .emacs file

(add-hook 'LaTeX-mode-hook
          (lambda ()
             '("axiom" LaTeX-env-label)
             '("assumption" LaTeX-env-label))))
(setq reftex-label-alist
      '(("axiom"   ?a "ax:"  "~\\ref{%s}" nil ("axiom"   "ax."))
        ("assumption"   ?s "asp:"  "~\\ref{%s}" nil ("assumption"   "assum."))))

I also set reftex-plug-into-AUCTeX to t.

When pressing C-c C-e, the label for the axiom environment will be automatically numbered based on the current document, but the label for the assumption environment requires manual input. Both environments are defined in the document.

I don't know what the difference is. Am I missing something in my .emacs file? Any help is greatly appreciated.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]