auctex-devel
[Top][All Lists]
Advanced

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

Re: [AUCTeX-devel] Minor bug and a few other things


From: Tassilo Horn
Subject: Re: [AUCTeX-devel] Minor bug and a few other things
Date: Thu, 30 Apr 2015 21:32:08 +0200
User-agent: Gnus/5.130012 (Ma Gnus v0.12) Emacs/25.0.50 (gnu/linux)

Marcin Borkowski <address@hidden> writes:

>> 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?

Actually, I don't know either.  It's just that SMIE seems to be the way
to go if one wants to provide solid indentation and navigation without
too much effort.  But of course it is possible that SMIE doesn't work in
our case.

But the above doesn't look too bad to me, at least not so bad that you
couldn't write it down as grammar.

  BIGL   => '\bigl' OPAREN
  OPAREN => '(' | '[' | '\langle' | '\{'
  BIGR   => '\'? 'bigr' CPAREN
  CPAREN => ')' | '[' | '|'
  ...

> (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;-).)

Oh, we need TeX experts here!  I'm only a mere mortal LaTeX user whose
knowledge is enough to write his documents but I've never coded some
moderately advanced TeX stuff.  Actually, whenever I can, I use LuaLaTeX
and then I call Lua from TeX to do complicated calculations and emit the
results as TeX again.  ;-)

Bye,
Tassilo




reply via email to

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