Uwe Brauer <o...@mat.ucm.es> writes: > > If you want to put that stuff in your .emacs, try something like this: > > > (with-eval-after-load "latex" > > (add-to-list 'LaTeX-label-alist '("titledquestion" . > LaTeX-exam-label))) > > > (require 'reftex) > > > (add-to-list 'reftex-label-alist > > `("titledquestion" ?x > > ,(concat LaTeX-exam-label "%f:") > > "~\\ref{%s}" nil ("ejercicio") )) > > The latter did not work. > > I tried emacs -Q > and loaded the file > > (require 'reftex) > (add-to-list 'reftex-label-alist > `("titledquestion" ?x > ,(concat LaTeX-exam-label "%f:") > "~\\ref{%s}" nil ("ejercicio") )) > and obtained > > cons: Symbol's value as variable is void: LaTeX-exam-label
Sigh, sorry, my bad. `LaTeX-exam-label' is not defined at that point of time. Please try this: --8<---------------cut here---------------start------------->8--- (with-eval-after-load "latex" (add-to-list 'LaTeX-label-alist '("titledquestion" . LaTeX-exam-label))) (with-eval-after-load "tex-style" (add-to-list 'reftex-label-alist `("titledquestion" ?x ,(concat LaTeX-exam-label "%f:") "~\\ref{%s}" nil ("ejercicio") ))) --8<---------------cut here---------------end--------------->8--- Best, Arash _______________________________________________ auctex-devel mailing list auctex-devel@gnu.org https://lists.gnu.org/mailman/listinfo/auctex-devel