Hi all, I am trying to do the following in Metapost but my new math symbol is not recognized. Context knows about it but Tex does not. How can I make this work ? Kind regards Wim Neimeijer % ================= Test code ======================== \loadmapfile[original-youngryu-tx.map] \definebodyfont [28pt,24pt,18pt, 17.3pt,14.4pt,12pt,11pt,10pt,9pt,8pt,7pt,6pt,5pt,4pt] [mm] [ mc=txexa sa 1] \setupbodyfont [11pt] \definemathsymbol [varointctrclockwise] [op] [mc] ["2B] [mc] ["2C] \starttext \startformula \varointctrclockwise_{\gamma} f(z) \: dz = 0 \stopformula \startMPcode picture p ; path q; numeric u; u := 1cm; p := btex $\varointctrclockwise_{\gamma} f(z) \: dz = 0$ etex; p := p scaled 0.15cm; draw p; \stopMPcode \stoptext =============== Log file ==============================
texmfstart texexec --autopdf --pdf testvaroint.tex TeXExec | processing document 'testvaroint.tex' TeXExec | no ctx file found TeXExec | tex processing method: context TeXExec | TeX run 1 TeXExec | writing option file testvaroint.top TeXExec | using randomseed 1260 TeXExec | tex engine: pdfetex TeXExec | tex format: cont-en TeXExec | progname: context This is pdfeTeX, Version 3.141592-1.30.3-2.2 (Web2c 7.5.5) \write18 enabled. (f:\context\usr\local\context\tex\texmf-local/web2c/natural.tcx) entering extended mode (./testvaroint.tex
22->2:3 us->ec:ec->23->2:3 agr->agr:agr->24->2:3 da->ec:ec->25->2:3 sv->ec:ec- 26->2:3 af->ec:ec->27->2:3 no->ec:ec->28->2:3 deo->ec:ec->29->2:3 es->ec:ec->3 0->2:3 ca->ec:ec->31->2:3 la->ec:ec->32->2:3 ro->ec:ec->33->2:3
22->2:3 us->ec:ec->23->2:3 agr->agr:agr->24->2:3 da->ec:ec->25->2:3 sv->ec:ec- 26->2:3 af->ec:ec->27->2:3 no->ec:ec->28->2:3 deo->ec:ec->29->2:3 es->ec:ec->3 0->2:3 ca->ec:ec->31->2:3 la->ec:ec->32->2:3 ro->ec:ec->33->2:3
ConTeXt ver: 2006.07.14 12:08 fmt: 2006.7.14 int: english mes: english
language : language en is active
WN wrote:
Hi all,
I am trying to do the following in Metapost but my new math symbol is not recognized. Context knows about it but Tex does not.
How can I make this work ?
Kind regards Wim Neimeijer
% ================= Test code ======================== \loadmapfile[original-youngryu-tx.map] \definebodyfont [28pt,24pt,18pt, 17.3pt,14.4pt,12pt,11pt,10pt,9pt,8pt,7pt,6pt,5pt,4pt] [mm] [ mc=txexa sa 1]
\setupbodyfont [11pt] \definemathsymbol [varointctrclockwise] [op] [mc] ["2B] [mc] ["2C]
\starttext \startformula \varointctrclockwise_{\gamma} f(z) \: dz = 0 \stopformula \startMPcode picture p ; path q; numeric u;
u := 1cm;
p := btex $\varointctrclockwise_{\gamma} f(z) \: dz = 0$ etex; p := p scaled 0.15cm; draw p; \stopMPcode \stoptext
make sure that mp knows about the definitions: - first extend the math collection (use decimen, since there is a linesplit bug with " here) - then load the times font - somehow display and inline math render differently; something for taco \startMPenvironment[global] \startmathcollection [default] \definemathsymbol [varointctrclockwise] [op] [mc] [43] [mc] [44] \stopmathcollection \usetypescript[times][ec] \setupbodyfont[times,11pt] \stopMPenvironment \starttext why the funny .15cm scale ... \startformula \varointctrclockwise_{\gamma} f(z) \: dz = 0 \stopformula $\varointctrclockwise_{\gamma} f(z) \: dz = 0$ \startMPcode draw btex $\varointctrclockwise_{\gamma} f(z) \: dz = 0$ etex scaled 0.15cm ; \stopMPcode \startMPcode draw btex $\displaystyle \varointctrclockwise_{\gamma} f(z) \: dz = 0$ etex scaled 0.15cm ; \stopMPcode \stoptext ----------------------------------------------------------------- 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 -----------------------------------------------------------------
Hans Hagen wrote:
make sure that mp knows about the definitions:
- first extend the math collection (use decimen, since there is a linesplit bug with " here) - then load the times font
Math family mc has to be txexa or something similar before the code actually shows the integral instead of a plus sign, but Wim can figure that out himself, no doubt :-)
- somehow display and inline math render differently; something for taco
That is normal. One is with an operator with \limits, one without. Taco
On Wed, 19 Jul 2006, WN wrote:
Hi all,
I am trying to do the following in Metapost but my new math symbol is not recognized. Context knows about it but Tex does not.
How can I make this work ?
Hans and Taco have already explained the correct way to do this, so I will not go into that. This is one place where you can use the new sometxt feature.
% ================= Test code ======================== \loadmapfile[original-youngryu-tx.map] \definebodyfont [28pt,24pt,18pt, 17.3pt,14.4pt,12pt,11pt,10pt,9pt,8pt,7pt,6pt,5pt,4pt] [mm] [ mc=txexa sa 1]
\setupbodyfont [11pt] \definemathsymbol [varointctrclockwise] [op] [mc] ["2B] [mc] ["2C]
\starttext \startformula \varointctrclockwise_{\gamma} f(z) \: dz = 0 \stopformula \startMPcode picture p ; path q; numeric u;
u := 1cm;
p := btex $\varointctrclockwise_{\gamma} f(z) \: dz = 0$ etex;
Replace this by p := \sometxt{$\varointctrclockwise_{\gamma} f(z) \: dz = 0$} ; and everything works!
p := p scaled 0.15cm; draw p; \stopMPcode \stoptext
Aditya
adityam@umich.edu wrote:
On Wed, 19 Jul 2006, WN wrote:
Hi all,
I am trying to do the following in Metapost but my new math symbol is not recognized. Context knows about it but Tex does not.
How can I make this work ?
Hans and Taco have already explained the correct way to do this, so I will not go into that. This is one place where you can use the new sometxt feature.
% ================= Test code ======================== \loadmapfile[original-youngryu-tx.map] \definebodyfont [28pt,24pt,18pt, 17.3pt,14.4pt,12pt,11pt,10pt,9pt,8pt,7pt,6pt,5pt,4pt] [mm] [ mc=txexa sa 1]
\setupbodyfont [11pt] \definemathsymbol [varointctrclockwise] [op] [mc] ["2B] [mc] ["2C]
\starttext \startformula \varointctrclockwise_{\gamma} f(z) \: dz = 0 \stopformula \startMPcode picture p ; path q; numeric u;
u := 1cm;
p := btex $\varointctrclockwise_{\gamma} f(z) \: dz = 0$ etex;
Replace this by
p := \sometxt{$\varointctrclockwise_{\gamma} f(z) \: dz = 0$} ;
and everything works!
I was wondering about the \sometxt feature, I did not know exactly how to use it, but will certainly do some experiments. Thanks Wim.
p := p scaled 0.15cm; draw p; \stopMPcode \stoptext
Aditya _______________________________________________ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
participants (4)
-
Aditya Mahajan
-
Hans Hagen
-
Taco Hoekwater
-
WN