[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [AUCTeX] Easylist with auctex
From: |
Arash Esbati |
Subject: |
Re: [AUCTeX] Easylist with auctex |
Date: |
Thu, 07 Feb 2019 21:13:40 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 |
Thorsten Grothe <address@hidden> writes:
> I would like to use the easylist package with auctex. Easylist is a
> enumerate/itemize like environment with the following structure
>
> \begin{easylist}
> # Item 1
> ## Item 2
> ### Item 3
> # Item 4
> \end{easylist}
>
> I could sucessfully register the env with
>
> (TeX-add-style-hook
> "latex"
> (lambda ()
> (LaTeX-add-environments
> '("easylist" LaTeX-env-item))))
>
> but I was not sucessfull registering “#/##/###…” as \items. How can I
> register #
> as \items to get the right indention/formatting/filling in the
> environment?
Hi Thorsten,
the usual way to introduce new \item-like macros to AUCTeX is to add
them to the variable `LaTeX-item-regexp'. The fun part is that AUCTeX
always adds a `(regexp-quote TeX-esc)' to the places where this variable
is used. To answer your question, I don't see an easy way to add single
characters without a backslash to AUCTeX without some
hacking/overwriting/advising of internal functions.
If want to give a roll, search for `LaTeX-item-regexp' in latex.el.
Best, Arash