[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [AUCTeX-devel] Minor bug and a few other things
From: |
Lars Madsen |
Subject: |
Re: [AUCTeX-devel] Minor bug and a few other things |
Date: |
Thu, 30 Apr 2015 07:50:15 +0000 |
wouldn't the best thing be the predefine "known" pairs of delimiters. That
should make it a lot easier to get the correct nesting level.
I have a construction to handle scalers plus () and [] (it is using sexp to
find the matching end brace). I'd like to see something more general such that
a key stroke can search forward from the current position locate the first
"left left" and mark the corresponding "right fence" and ask for which type of
scaling.
That might be a better starting point than attempting to cover every scaler +
fence combo known. Some are frequently used, others not so much.
/Lars Madsen
Institut for Matematik / Department of Mathematics
Aarhus Universitet / Aarhus University
Mere info: http://au.dk/address@hidden / More information:
http://au.dk/en/address@hidden
________________________________________
From: address@hidden address@hidden on behalf of Marcin Borkowski address@hidden
Sent: 29 April 2015 22:21
To: address@hidden
Subject: Re: [AUCTeX-devel] Minor bug and a few other things
On 2015-04-29, at 08:23, Tassilo Horn <address@hidden> wrote:
> Marcin Borkowski <address@hidden> writes:
>
> Hi Marcin,
>
>> this is a bit nitpicky, but I'm studying tex.el, and I found yet
>> another (very minor) docstring bug. The docstring for
>> TeX-string-divide-number-unit says "Return the number as car and unit
>> as cdr", but in fact it returns a two-element list, not a dotted pair.
>
> Corrected.
Thanks!
>> OTOH, I'm working on my delimiter managing code. I can now find a
>> matching \right or \bigl or \biggl etc., and enlarge or diminish both
>> sides (e.g., go from \bigl .. \bigr to \Bigl .. \Bigr etc.) with a
>> keystroke. Next in the queue is LaTeX-delimiter-aware
>> show-paren-mode, which will highlight matching "\right." when we are
>> at "\left\{" etc.
>
> Do you use SMIE for that (info "(elisp)SMIE")? It would be very cool if
> one could use `forward-sexp'/`backward-sexp' for navigating (La)TeX
> code.
No, but I'll take a look. I'm afraid, though, that it might not be
enough. Consider these cases:
\bigl( .. \bigr)
\bigl[ .. \bigr)
\bigl[ .. bigr[ % this is no mistake, some people use this notation!
\left\{ .. \right.
\bigl\langle .. \bigr)
\bigl[ .. \bigr|
\langle .. )
All the above are valid, paired delimiters. Can SMIE handle that? (I'm
not saying it can't, I just want to know. Reading its docs will take me
some time, and I won't be able to do it until at least Friday. In fact,
I'm just back home from a one-day visit at a TeX conference;-).)
>> And while we are at it, there's an annoying typo in mathtools.el:
>> three times it says "delimeter" instead of "delimiter".
>
> Fixed. Thank you!
You're welcome!
> Bye,
> Tassilo
Best,
--
Marcin Borkowski
http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski
Faculty of Mathematics and Computer Science
Adam Mickiewicz University
_______________________________________________
auctex-devel mailing list
address@hidden
https://lists.gnu.org/mailman/listinfo/auctex-devel