You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The code for doing this:
\gdef\ProcessAsymptoteLine#1^^M{%
\def@tempa{#1}%
{%
\escapechar=-1\relax%
\xdef@tempb{\string\end\string{\CurrentAsymptote\string}}%
}% \ifx@tempa@tempb%
\edef\next{\endgroup\noexpand\end{\CurrentAsymptote}}%
\else%
\ThisAsymptote{#1}%
\let\next\ProcessAsymptoteLine% \fi%
\next%
}
The lines in boldface test for the line match.
It appears (naively?) to be pretty easy to extend the definition of this macro to one that it terminates after exactly one line. Why might this be useful?
It could be used within other macros since it does on depend on line breaks.
It is unaffected by an unexpected reformatting.
It would be convenient for small inserts.
One line may have many semicolons 😄.
Any thoughts?
The text was updated successfully, but these errors were encountered:
The asy environment used for inline code within a LaTeX document is defined starting on line 244 here: https://github.com/vectorgraphics/asymptote/blob/master/doc/asy-latex.dtx). Lines are read in one at a time until one matches \end{asy}.
The code for doing this:
\gdef\ProcessAsymptoteLine#1^^M{%
\def@tempa{#1}%
{%
\escapechar=-1\relax%
\xdef@tempb{\string\end\string{\CurrentAsymptote\string}}%
}%
\ifx@tempa@tempb%
\edef\next{\endgroup\noexpand\end{\CurrentAsymptote}}%
\else%
\ThisAsymptote{#1}%
\let\next\ProcessAsymptoteLine%
\fi%
\next%
}
The lines in boldface test for the line match.
It appears (naively?) to be pretty easy to extend the definition of this macro to one that it terminates after exactly one line. Why might this be useful?
Any thoughts?
The text was updated successfully, but these errors were encountered: