auctex
[Top][All Lists]
Advanced

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

Re: Some LaTeX commands, such as \boldsymbol and \hspace, can't be compl


From: Arash Esbati
Subject: Re: Some LaTeX commands, such as \boldsymbol and \hspace, can't be completed in AUCTeX.
Date: Wed, 08 Dec 2021 12:39:25 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50

Denis Bitouzé <denis.bitouze@univ-littoral.fr> writes:

> Le 08/12/21 à 11h45, Jean-Jacques Rétorré a écrit :
>
>>> Compared to LaTeX IDE, e.g. TeXstudio, AUCTeX is much less handy from
>>> this point of view. Would be nice for this aspect to be improved :)
>>>
>>
>> Adds
>>
>>         (TeX-add-symbols '("linewidth")) :....
>>
>> in your intit file, and all symbol who lacks.
>
> IMO, it's something that should be provided by the editor (or, here, by
> AUCTeX), not done by the user.

AUCTeX has support for \hspace, just try `C-c C-m hs<TAB> RET' and when
asked for 'Length: ", press TAB and check the completion.  \linewidth is
also available.

> And, in this respect, AUCTeX is much less handy than e.g. TeXstudio.

Can you please elaborate what exactly you mean?  I'm not sure if I get
the point.

>> Usually they come with the style file associated to a package
>
> At least \hspace and \linewidth are core LaTeX macros.

They are there:

http://git.savannah.gnu.org/cgit/auctex.git/tree/latex.el#n7179
http://git.savannah.gnu.org/cgit/auctex.git/tree/latex.el#n7034

I think the only thing you're missing is that there is no \linewidth
macro defined in AUCTeX.  AUCTeX records all known lengths in
`LaTeX-length-list' and use it for completion where needed.  Usually,
you don't write \linewidth in the middle of a document.

> BTW, a TeXstudio contributor is in the way of providing completion files
> for all the classes/packages! Of course, the format of such (`.cwl`)
> files is specific to TeXstudio but maybe they could be converted in
> completion files for AUCTeX.

AUCTeX has also some of them 🙂

http://git.savannah.gnu.org/cgit/auctex.git/tree/style

Any specific package you're missing?

Best, Arash




reply via email to

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