metafun & textext problems in mkiv
Hello Hans, this fails in mkiv: \setupcolors[state=start] \starttext \startMPpage picture p; p := textext("abc"); draw p withcolor red; draw p shifted (3cm,0) withcolor blue; \stopMPpage \stoptext Mojca
This also has problems - withpen is ignored: \starttext \startMPpage draw origin--(10cm,0) withpen pencircle scaled 50; \stopMPpage \stoptext Thanks, Mojca
On Fri, Aug 29, 2008 at 7:06 PM, Mojca Miklavec wrote:
This also has problems - withpen is ignored:
\starttext \startMPpage draw origin--(10cm,0) withpen pencircle scaled 50; \stopMPpage \stoptext
I'm sorry ... accidental usage of TL's luatex. Minimals seem to work fine with that. However, with both mkii and latest luatex + context I now get another problem that otherwise works with TL's version. Pure lottery :) :) :) Mojca
Mojca Miklavec wrote:
On Fri, Aug 29, 2008 at 7:06 PM, Mojca Miklavec wrote:
This also has problems - withpen is ignored:
\starttext \startMPpage draw origin--(10cm,0) withpen pencircle scaled 50; \stopMPpage \stoptext
I'm sorry ... accidental usage of TL's luatex. Minimals seem to work fine with that.
had to do with a one point path that needs specal treatment; was indeed fixed
However, with both mkii and latest luatex + context I now get another problem that otherwise works with TL's version.
as long as no example ... everything is fine Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
Mojca Miklavec wrote:
Hello Hans,
this fails in mkiv:
\setupcolors[state=start] \starttext \startMPpage picture p; p := textext("abc"); draw p withcolor red; draw p shifted (3cm,0) withcolor blue; \stopMPpage \stoptext
this is because text is handled at the tex end and color happens with attributes; i can hack a solution but i'm still wondering if it is really needed (will make code dirty) textext("\red abc"); works Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
On Sat, Aug 30, 2008 at 12:36 AM, Hans Hagen wrote:
Mojca Miklavec wrote:
Hello Hans,
this fails in mkiv:
\setupcolors[state=start] \starttext \startMPpage picture p; p := textext("abc"); draw p withcolor red; draw p shifted (3cm,0) withcolor blue; \stopMPpage \stoptext
this is because text is handled at the tex end and color happens with attributes; i can hack a solution but i'm still wondering if it is really needed (will make code dirty)
It's not only about "color doesn't work" (though it would be really nice if it would, but there have been many incompatibilities in that respect since the introduction of \sometxt anyway), but the picture also gets lost second time when it's used. I only get one "abc" and empty space instead of the second one. (The third problem mentioned turned out to be just a bug in my code that happened to work with an older version of mkiv.) Mojca
Mojca Miklavec wrote:
It's not only about "color doesn't work" (though it would be really nice if it would, but there have been many incompatibilities in that respect since the introduction of \sometxt anyway), but the picture also gets lost second time when it's used. I only get one "abc" and empty space instead of the second one.
in mlib-pps.tex we need a \copy instead of a \box \def\MPLIBgettextscaled#1#2#3% {\vbox to \zeropoint{\vss\hbox to \zeropoint{\scale[sx=#2,sy=#3]{\raise\dp#1\copy#1}\hss}}} ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
On Sun, Aug 31, 2008 at 12:26 PM, Hans Hagen wrote:
Mojca Miklavec wrote:
It's not only about "color doesn't work" (though it would be really nice if it would, but there have been many incompatibilities in that respect since the introduction of \sometxt anyway), but the picture also gets lost second time when it's used. I only get one "abc" and empty space instead of the second one.
in mlib-pps.tex we need a \copy instead of a \box
\def\MPLIBgettextscaled#1#2#3% {\vbox to \zeropoint{\vss\hbox to \zeropoint{\scale[sx=#2,sy=#3]{\raise\dp#1\copy#1}\hss}}}
Thanks a lot, it works OK now. (Colors don't, but I guess that this is more or less on purpose.) Mojca
participants (2)
-
Hans Hagen
-
Mojca Miklavec