wspr / breqn

Automatic line breaking in LaTeX equations
18 stars 2 forks source link

flexisym problem #31

Open u-fischer opened 4 years ago

u-fischer commented 4 years ago

flexisym tries to patch the \@begindocumenthook by using some commands as marker:

\@ifpackageloaded{amsmath}{%
  \begingroup\show\@begindocumenthook
  \long\def\next#1\mathchardef\std@minus\mathcode`\-\relax
                  \mathchardef\std@equal\mathcode`\=\relax#2\flexi@stop{%
    \toks@{#1#2}%
    \xdef\@begindocumenthook{\the\toks@}%
  }%
  \expandafter\next\@begindocumenthook\flexi@stop
  \endgroup
}{}

This breaks now if a user uses it together with unicode-math:

https://tex.stackexchange.com/questions/514086/error-in-breqn-flexisym-sty-when-using-breqn-with-libertinus-font

wspr commented 4 years ago

Ah. I should have caught that, sorry. I wonder if the patching needed here and elsewhere for amsmath could instead by taken up by amsmath itself... (for some reason I thought David tried to do that at some stage, but I guess not).

davidcarlisle commented 4 years ago

I'm certainly keen to incorporate amsmath patches from unicode-math and lualatextex-math.sty into amsmath, not so sure about breqn/flexisym which seem rather more experimental...

intractabilis commented 3 years ago

What should I do if I encounter this error?