lualatex / luamplib

generic TeX package - including MetaPost code in LuaTeX documents
http://ctan.org/pkg/luamplib
16 stars 11 forks source link

Labels outside beginfig...endfig are not inherited #70

Closed z-rui closed 4 years ago

z-rui commented 6 years ago

Sample:

\input luamplib.sty
\mplibcodeinherit{enable}
\mplibglobaltextext{enable}

% Problem: without the next line, the label is not drawn (only the dot is drawn).
\everymplib{ beginfig(0);}\everyendmplib{ endfig;}%
\mplibcode
picture pic;
pic := image(
    dotlabel.top(TEX("x"), origin);
);
\endmplibcode

\everymplib{ beginfig(0);}\everyendmplib{ endfig;}%
\mplibcode
 currentpicture := pic scaled 2;
\endmplibcode
\bye
dohyunkim commented 6 years ago

Verified the issue. But for now I don't have enough time; I'll investigate the issue some time later.

dohyunkim commented 6 years ago

Just released an update, which is expected to appear in TL in a few days.
Hope this version has addressed the issue.