On 4-5-2011 12:22, Julian Becker wrote:
This seems to be still broken :-(
The \intertext{} workaround however is still working, luckily

2010/11/23 Vladimir Lomov<lomov...@gmail.com>

** Aditya Mahajan [2010-11-23 11:17:55 -0500]:

On Wed, 24 Nov 2010, Vladimir Lomov wrote:

Hi.

The example with start/stopintertext from 'mathalign.pdf' (My Way, Using
\startalign and friends,
Aditya Mahajan) gives error with current context (beta):
<example file="ex2.tex">
%%% Seems that there is a problem with \start/stopintertext . This
command is described in mathalign.pdf
%%% (MyWay).

\starttext

Here the start/stopintertext should give text between formulas
\startformula
\startalign
   \NC \exp^{\imath t}=\cos t+\imath\sin t\NR
\startintertext
   This is famous Euler formula, below one is known as Moivre formula
\stopintertext
   \NC (\cos x + \imath\sin x)^{m} = \cos mx+\imath\sin mx \NR
\stopalign
\stopformula

That's it.

\stoptext
</example>

<error_message>
! Misplaced \noalign.
\startintertext #1\stopintertext ->\noalign
                                           {\dointertext {#1}}
l.12   \stopintertext
?
</error_message>

$ context --version

MTXrun | main context file:
/usr/local/opt/context/tex/texmf-context/tex/context/base/context.tex
MTXrun | current version: 2010.11.20 12:51

Is this a bug or I do something wrong?

Bug, and it seems a rather old one. It also fails with 2010.05.24.

has to do with the tex scanner in alignments (doesn't like unexpandable macros)

I cannot debug this right now. A quick workaround is to use
\intertext{...} instead.
Ok, thanks.

P.S. I thought that all start/stopXXX commands has cousin commands
\XXX. Seems that I was wrong.

%D The intertext commands have to be expandable (in aligment lookahead) so
%D we cannot use \type {\unexpanded}.

\let\stopintertext\relax

\def\startintertext#1\stopintertext
  {\noalign{\dointertext{#1}}}

\def\intertext#1%
  {\noalign{\dointertext{#1}}}


-----------------------------------------------------------------
                                          Hans Hagen | PRAGMA ADE
              Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
    tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
                                             | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

Reply via email to