[NTG-context] Construct a matrix with Metafun

Wolfgang Schuster wolfgang.schuster.lists at gmail.com
Sun Oct 14 12:30:02 CEST 2018


It works for me when I add a space after each \MPcode{…} block.

\math{\MATRIX{\MPcode{...} ;\MPcode{...} }}

Wolfgang


Fabrice Couvreur schrieb am 14.10.18 um 12:18:
> Hi Wolfgang,
> Thank you for your solution.The space came from copy-paste because if 
> I do this, it does not work :
>
> \definemathmatrix [pmatrix][matrix:parentheses][simplecommand=MATRIX]
>
> \starttext
>
> \math{\MATRIX{\MPcode{draw (0,0) -- (1cm,0);} ;\MPcode{draw (0,0) -- 
> (1cm,0);}}}
>
> \stoptext
>
> Fabrice
>
> Le dim. 14 oct. 2018 à 11:08, Wolfgang Schuster 
> <wolfgang.schuster.lists at gmail.com 
> <mailto:wolfgang.schuster.lists at gmail.com>> a écrit :
>
>
>
>     Fabrice Couvreur schrieb am 14.10.18 um 10:46:
>>     Hi,
>>     I tried to use Metafun and \definemathmatrix [pmatrix] [matrix:
>>     parentheses] [simplecommand = MATRIX] to create two matrices, but
>>     that does not work.
>
>     1. You have a space in [matrix: parentheses]
>
>     2. When you have only simple graphics like in your example you can
>     use framed.
>
>     \starttext
>
>     \startformula
>       A\,
>       \startmathmatrix[left=\left(,right=\right)]
>       \NC \framed[width=1em,height=1em,frame=off,bottomframe=on]{} \NC
>     \framed[width=1em,height=1em,frame=off,bottomframe=on,leftframe=on]{}
>     \NR
>       \NC \framed[width=1em,height=1em,frame=off,rightframe=on]{} \NC
>     \framed[width=1em,height=1em]{} \NR
>       \stopmathmatrix
>     \stopformula
>
>     \stoptext
>
>     Wolfgang
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.ntg.nl/pipermail/ntg-context/attachments/20181014/89dfa44e/attachment.html>


More information about the ntg-context mailing list