On 7/8/2020 12:00 AM, Jairo A. del Rio wrote:
Yep, now it finally works. Certainly it requires a few more lines. I was
going to rewrite some TikZ code which was too dependent on LaTeX and
xstring was the last stone on the shoe. Thank you a lot, Phelype and
Wolfgang (I didn't know about
On 7/8/2020 12:00 AM, Jairo A. del Rio wrote:
Yep, now it finally works. Certainly it requires a few more lines. I was
going to rewrite some TikZ code which was too dependent on LaTeX and
xstring was the last stone on the shoe. Thank you a lot, Phelype and
Wolfgang (I didn't know about
Yep, now it finally works. Certainly it requires a few more lines. I was
going to rewrite some TikZ code which was too dependent on LaTeX and
xstring was the last stone on the shoe. Thank you a lot, Phelype and
Wolfgang (I didn't know about push/popmacro either and now it's in my to-do
readings).
On Tue, Jul 7, 2020 at 6:21 PM Jairo A. del Rio wrote:
>
> Thank, Wolfgang! Both methods work, but both fail with the following example:
>
> \pushmacro\unexpanded
> \let\unexpanded\normalunexpanded
> \input xstring
> \popmacro\unexpanded
> \starttext
> \StrGobbleLeft{bcdef}{4}
> \stoptext
>
> The
Thank, Wolfgang! Both methods work, but both fail with the following
example:
\pushmacro\unexpanded
\let\unexpanded\normalunexpanded
\input xstring
\popmacro\unexpanded
\starttext
\StrGobbleLeft{bcdef}{4}
\stoptext
The log says:
tex error > tex error on line 6 in file ./tests.tex: ! This can't
On Tue, Jul 7, 2020 at 5:19 PM Wolfgang Schuster
wrote:
>
> Bad idea because ConTeXt also changes the meaning of \protected (you can
> use \normalprotected to get the primitve).
Oops, forgot about that one.
> A better version is
>
> \pushmacro\unexpanded
> \let\unexpanded\normalunexpanded
>
Phelype Oleinik schrieb am 07.07.2020 um 20:53:
Hi Jairo,
ConTeXt's \unexpanded is e-TeX's \protected, so the error boils down to
something like: \edef\x{\unexpanded{#}}, which works in Plain but not in
ConTeXt.
Usually packages that claim to be generic have to cope with that.
xstring would
I've tried with a wrapper and it seems to work fine. However, changing
definitions "on the fly" to make xstring usable seems to break things in
ConTeXt... Whatever. I guess I will have to find out other command
redefinitions in ConTeXt.
Thank you very much, Phelype.
Jairo :)
El mar., 7 de jul.
Hi Jairo,
ConTeXt's \unexpanded is e-TeX's \protected, so the error boils down to
something like: \edef\x{\unexpanded{#}}, which works in Plain but not in
ConTeXt.
Usually packages that claim to be generic have to cope with that.
xstring would need to do (in a ConTeXt-specific loader):
Reading about macro bundles meant to be generic (format agnostic), some of
them work in plain/LaTeX, but crash when loaded on ConTeXt. The following
happens with xstring.tex
tex error > tex error on line 372 in file xstring.tex: ! Illegal parameter
number in definition of \xs_reserved_C
1
10 matches
Mail list logo