olsak/OpTeX

Wrong \foreach while loading some libraries in tikz

cao- opened this issue · 2 comments

cao- commented

When trying to load some libraries in Tikz, using the \usetikzlibrary command, the macro \foreach has the OpTeX definition rather than that of Tikz. Here is an example that fails:

\load[tikz]
\usetikzlibrary{graphs}
\bye

It doesn't fail if i redefine \foreach:

\load[tikz]\let\foreach=\_pgf_foreach
\usetikzlibrary{graphs}
\bye

I see that in tikz.opm we have \addto \tikz@startup@env {\let\foreach=\pgffor@foreach}: maybe there is some other Tikz macro that we should modify in the same way.

olsak commented

Thank you for bug report. I tried to solve it by my last commit.

cao- commented

Thank you for solving it :)