From: Stefi <stefi@freitagsrunde.org>
To: Kyle Meyer <kyle@kyleam.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: Bug: no math-mode detection for align-environment [9.3.7 (9.3.7-13-ge62ca4-elpaplus @ /home/stefi/.emacs.d/elpa/org-plus-contrib-20200713/)]
Date: Mon, 10 Aug 2020 12:50:57 +0200 [thread overview]
Message-ID: <75354f45-5fb7-423b-3aa8-a25c790929c3@freitagsrunde.org> (raw)
In-Reply-To: <87pn8fm2ux.fsf@kyleam.com>
Hi Kyle, hi mailing list,
I also evaluated (org-inside-LaTeX-fragment-p) and got non-nil values
for all blocks, however, inside the align* environment, the "fr" does
not get expanded on TAB whereas it does in equation environment. So
either the matchers do not include align/align*, or there is something
different now with cdlatex.
Btw, this is what I got from evaluation:
(#("\\begin{align*} 0 14 (fontified t line-prefix #(" " 0 4 ...)
wrap-prefix # (" " 0 4 ...))) . 15791)
and
(#("\\begin{equation} 0 16 (fontified t line-prefix #(" " 0 4 ...)
wrap-prefix # (" " 0 4 ...))) . 15824)
Does someone know how to find and configure the matchers?
I am pretty sure it worked before with align* environment, as I am using
it all the time :)
regards
On 7/29/20 5:12 AM, Kyle Meyer wrote:
> Stefi writes:
>
>> I recently updated my emacs packages and noticed that \begin{align*}
>> does not trigger math-mode detection any more, so org-cdlatex does not
>> work. However, begin{equation} still does trigger the math-mode
>> detection. I have read the documentation of
>> "org-inside-LaTeX-fragment-p" and found something about matchers, but
>> nothing about equation or align environment and why it might be treated
>> differently for math-mode detection.
>
> The default value for :matches is ("begin" "$1" "$" "$$" "\\(" "\\[").
> It looks like the value hasn't been touched in a long time, and that
> AFAICT the "begin" should cover "align" just as it covers "equation".
> And I'm not spotting any recent changes on Org's end that should affect
> this.
>
>> My test-file.org:
>> ----8<---------8<---------8<---------8<-----
>>
>> * blabla
>> \begin{equation}
>> \label{eq:1} \frac{}{}
>> test_{cds} \frac{}{}
>> \end{equation}
>>
>> \begin{align}
>> \label{eq:2}
>> test$_d$ fr
>> \end{align}
>>
>> $\frac{}{} fds_{fdsf} \frac{}{}$
>>
>> \begin{align*}
>> fr
>> \end{align*}
>>
>>
>> ----8<---------8<---------8<---------8<-----
>>
>> - detection works for: \begin{equation}, $$, \[\] (not in testfile)
>> - detection does not work for: \begin{align}, begin{align*}; subscript _
>> does insert extra $_{}$, which it should not in math mode, and fr does
>> not get expanded to \frac{}{}
>>
>> Emacs : GNU Emacs 26.3 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.20)
>> of 2020-05-19
>> Package: Org mode version 9.3.7 (9.3.7-13-ge62ca4-elpaplus @
>> /home/stefi/.emacs.d/elpa/org-plus-contrib-20200713/)
>
> On master, maint, and the commit matching your reported version
> (e62ca4), I tried org-inside-LaTeX-fragment-p within each block of your
> test file, and it returns non-nil, including in the align and align*
> blocks. So I dunno...
>
> Could some org-cdlatex users out there give the test file a try?
>
next prev parent reply other threads:[~2020-08-10 10:51 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-14 11:49 Bug: no math-mode detection for align-environment [9.3.7 (9.3.7-13-ge62ca4-elpaplus @ /home/stefi/.emacs.d/elpa/org-plus-contrib-20200713/)] Stefi
2020-07-29 3:12 ` Kyle Meyer
2020-08-05 20:19 ` Rafael
2020-08-10 10:50 ` Stefi [this message]
2020-08-26 3:44 ` Kyle Meyer
2020-08-26 18:05 ` Stefi
2020-08-27 11:39 ` Stefi
2020-08-28 5:08 ` Kyle Meyer
2020-08-28 6:55 ` Carsten Dominik
2020-08-29 13:27 ` Stefi
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=75354f45-5fb7-423b-3aa8-a25c790929c3@freitagsrunde.org \
--to=stefi@freitagsrunde.org \
--cc=emacs-orgmode@gnu.org \
--cc=kyle@kyleam.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).