Re: [NTG-context] Place a text over an arrow (Metafun)

2016-07-25 Thread Hans Hagen
p 5cm \relax \dontleavehmode\useMPgraphic{MyArrow} \math{A^{-1}\times A\times X=A^{-1}\times B} \hfill On utilise l'égalité \math{A^{-1}\times A=I}. \hskip 5cm \relax \dontleavehmode \useMPgraphic{MyArrow} \math{I\times X=A^{-1}\times B} \hfill On utilise l'égalité \math{X\times I=I\time

[NTG-context] Place a text over an arrow (Metafun)

2016-07-25 Thread Fabrice Couvreur
,-0.6cm)..(0,-1.2cm){left} ; drawarrow p withpen pencircle scaled 1.5bp withcolor 0.625white ; \stopuseMPgraphic \starttext \showgrid \math{A\times X=B} \hfill On multiplie, à gauche, les deux membres de l'égalité par \math{A^{-1}}. \hskip 5cm \relax \dontleavehmode\useMPgraphic{MyArrow}

[NTG-context] Colors not showing inside metapost after \showcolor

2016-07-23 Thread Bou Salim
\MPcolor{myred}; \stopuseMPgraphic \midaligned{\useMPgraphic{test}} \stoptext ___ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www

Re: [NTG-context] Remove files that are not needed (Metafun)

2016-07-12 Thread Fabrice Couvreur
t; >> scaled 5pt >> withfillcolor \MPcolor{lightgray} >> withpen pencircle scaled 1pt ; ) ; >> draw r ; >> \stopusableMPgraphic >> >> \def\processMPheadnumber#1% >> {\useMPgraphic{NumberHead}} >> >> \setuphead >>

Re: [NTG-context] Remove files that are not needed (Metafun)

2016-07-12 Thread Hans Hagen
quot; scaled 5pt withfillcolor \MPcolor{lightgray} withpen pencircle scaled 1pt ; ) ; draw r ; \stopusableMPgraphic \def\processMPheadnumber#1% {\useMPgraphic{NumberHead}} \setuphead [chapter] [command=\HeadTitle, headstyle=\ss, numbercommand=

Re: [NTG-context] Remove files that are not needed (Metafun)

2016-07-12 Thread Fabrice Couvreur
apter}" scaled 5pt withfillcolor \MPcolor{lightgray} withpen pencircle scaled 1pt ; ) ; draw r ; \stopusableMPgraphic \def\processMPheadnumber#1% {\useMPgraphic{NumberHead}} \setuphead [chapter] [command=\HeadTitle, headstyle=\ss, num

Re: [NTG-context] \currentheadnumber does not work

2016-07-11 Thread Fabrice Couvreur
>> r := image ( graphictext >> \MPstring{chapter} >> scaled 4pt >> withfillcolor \MPcolor{lightgray} >> withpen pencircle scaled 1pt ; ) ; >> draw r ; >> \stopusableMPgraphic >> >> \defineoverl

Re: [NTG-context] \currentheadnumber does not work

2016-07-10 Thread Fabrice Couvreur
\MPstring{chapter} > scaled 4pt > withfillcolor \MPcolor{lightgray} > withpen pencircle scaled 1pt ; ) ; > draw r ; > \stopusableMPgraphic > > \defineoverlay[NumberHead][\uniqueMPgraphic{NumberHead}] > > \def\processMPheadnumber#1%

Re: [NTG-context] \currentheadnumber does not work

2016-07-09 Thread Wolfgang Schuster
raphic{NumberHead}] \def\processMPheadnumber#1% {\setMPtext{chapter}{\bf#1} \useMPgraphic{NumberHead}} \setuphead [chapter] [command=\HeadTitle, headstyle=\ss, numbercommand=\processMPheadnumber{\currentheadnumber}] The following works here. \startusableMPgraphic{NumberHead} p

Re: [NTG-context] \currentheadnumber does not work

2016-07-09 Thread Fabrice Couvreur
\defineoverlay[NumberHead][\uniqueMPgraphic{NumberHead}] \def\processMPheadnumber#1% {\setMPtext{chapter}{\bf#1} \useMPgraphic{NumberHead}} \unexpanded\def\HeadTitle#1#2% {\framed [frame=off, bottomframe=on, width=broad, align={broad,nothyphenated,left}] {#1\blank

Re: [NTG-context] Baseline and framed

2016-07-06 Thread Fabrice Couvreur
gt; > \unexpanded\def\processMPheadnumber#1% > {\setMPtext{chapter}{\bf#1} >\useMPgraphic{chapter}} > > \setuphead >[chapter] >[command=\HeadTitle, > numbercommand=\processMPheadnumber{\currentheadnumber}] > > \starttext > > \startchap

Re: [NTG-context] Baseline and framed

2016-07-06 Thread Fabrice Couvreur
% {\setMPtext{chapter}{\bf#1} \useMPgraphic{chapter}} \setuphead [chapter] [command=\HeadTitle, numbercommand=\processMPheadnumber{\currentheadnumber}] \starttext \startchapter [title={Séries statistiques à deux variables}] \stopchapter \startchapter [title={Matrice

Re: [NTG-context] Partial \framed

2016-06-06 Thread Thomas Fehige
[0] = (-EmWidth,OverlayHeight) ; z[1] = (0,OverlayHeight) ; z[2] = (0,0) ; z[3] = (-EmWidth,0) ; draw z[0]--z[1]--z[2]--z[3] withcolor \MPcolor{\overlaylinecolor} ; \stopuseMPgraphic \installleftframerenderer {bracket}{\useMPgraphic {leftbracket}} \installrightframerenderer{bracket

Re: [NTG-context] Partial \framed

2016-06-06 Thread Wolfgang Schuster
(0,OverlayHeight) ; z[2] = (0,0) ; z[3] = (-EmWidth,0) ; draw z[0]--z[1]--z[2]--z[3] withcolor \MPcolor{\overlaylinecolor} ; \stopuseMPgraphic \installleftframerenderer {bracket}{\useMPgraphic {leftbracket}} \installrightframerenderer{bracket}{\useMPgraphic{rightbracket}} \definef

Re: [NTG-context] Thick border of one side of TR/TD

2016-05-22 Thread Lukáš Procházka
Hello, thanks for the answers. So my solution now is: \startuseMPgraphic{MP:ThickBtm} draw bottomboundary OverlayBox withpen pensquare scaled 1mm withcolor black; clip currentpicture to OverlayBox; \stopuseMPgraphic \installbottomframerenderer{Thick}{\useMPgraphic{MP:ThickBtm

Re: [NTG-context] Alignment/line break in a TABLE cell

2016-05-19 Thread Mari Voipio
eMPgraphic \definesymbol[box3mm][{\useMPgraphic{box3mm_filled}}] \starttext \dontleavehmode\symbol[box3mm] 1 \stoptext Thank you for your speedy replies! Mari On Thu, May 19, 2016 at 2:08 PM, Wolfgang Schuster wrote: > Mari Voipio > 19. Mai 2016 um 12:45 > On Thu, May 19, 2016 at 1:04 PM

Re: [NTG-context] Alignment/line break in a TABLE cell

2016-05-19 Thread Wolfgang Schuster
tleavehmode\symbol[square] 1 \stoptext 3. Use metapost to create your own box. \startuseMPgraphic{box3mm} draw unitsquare scaled 3mm ; \stopuseMPgraphic \definesymbol[box3mm][{\useMPgraphic{box3mm}}] \starttext \dontleavehmode\symbol[box3mm] 1 \stoptext

Re: [NTG-context] useMPgraphic scaling

2016-04-26 Thread Wolfgang Schuster
Meer, Hans van der 26. April 2016 um 08:50 Sure, is needed. Checked it again. I define \scalesetting as \edef\scalesetting{scale=\xmlattdef{#1}{scale}{1000}} But I am not sure why this needs the expansion.. The enclosing \rotate[rotation=\xmlattdef{#1}{rotation}{0}]

Re: [NTG-context] useMPgraphic scaling

2016-04-25 Thread Meer, Hans van der
On 25 Apr 2016, at 16:34, Hans Hagen mailto:pra...@wxs.nl>> wrote: On 4/25/2016 3:46 PM, Meer, Hans van der wrote: Thanks, Your reply popped up here exactly the moment I saw the light! Must be something Messed up the order things: Was: \scale[\scalesetting]{% \expanded{\useMPg

Re: [NTG-context] useMPgraphic scaling

2016-04-25 Thread Hans Hagen
On 4/25/2016 3:46 PM, Meer, Hans van der wrote: Thanks, Your reply popped up here exactly the moment I saw the light! Must be something Messed up the order things: Was: \scale[\scalesetting]{% \expanded{\useMPgraphic{\xmlatt{#1}{name}}{\xmlatt{#1}{parameters% And of course had to be

Re: [NTG-context] useMPgraphic scaling

2016-04-25 Thread Meer, Hans van der
Thanks, Your reply popped up here exactly the moment I saw the light! Must be something Messed up the order things: Was: \scale[\scalesetting]{% \expanded{\useMPgraphic{\xmlatt{#1}{name}}{\xmlatt{#1}{parameters% And of course had to be: \expanded{\scale[\scalesetting

Re: [NTG-context] useMPgraphic scaling

2016-04-25 Thread Hans Hagen
On 4/25/2016 1:11 PM, Meer, Hans van der wrote: With images one can scale them on placement, for example \externalfigure[][scale=250,height=..] etc. Is such a scaling or separate height,width setting also possible with the placement of useMPgraphic? Or needs all scaling of thesebe done within

[NTG-context] useMPgraphic scaling

2016-04-25 Thread Meer, Hans van der
With images one can scale them on placement, for example \externalfigure[][scale=250,height=..] etc. Is such a scaling or separate height,width setting also possible with the placement of useMPgraphic? Or needs all scaling of thesebe done within the metapost/metafun code? Hans van der Meer

Re: [NTG-context] \startuseMPgraphic

2016-04-11 Thread Alan BRASLAU
rtMPpage > fill fullcircle scaled 3cm withcolor \MPcolor{myred} ; > \stopMPpage > %% end example > > > The second part of the questions concerns metapost variables. > > %% begin example > \startuseMPgraphic{mycircle}{diameter,color} > fill fullcircle scaled \MPvariable{

Re: [NTG-context] \startuseMPgraphic

2016-04-11 Thread Wolfgang Schuster
tartTEXpage \useMPgraphic{mycircle}{diameter=3cm,color=red} \stopTEXpage %% end example The second argument of the \startuseMPgraphic command initializes the variables of your command and the \MPvariable accesses the value of the variable. In this case "color" is only the name of the variable and do

Re: [NTG-context] \startuseMPgraphic

2016-04-11 Thread Meer, Hans van der
gt; This is looking for a color named 'color'. You need \MPcolor{\MPvar{color}}. > > >> \stopuseMPgraphic >> \startuseMPgraphic{example2}{color} >> pickup pencircle scaled 1mm; >> draw unitsquare scaled 1

Re: [NTG-context] \startuseMPgraphic

2016-04-11 Thread Aditya Mahajan
stopuseMPgraphic \startuseMPgraphic{example2}{color} pickup pencircle scaled 1mm; draw unitsquare scaled 1cm withcolor \MPvar{color}; \stopuseMPgraphic \useMPgraphic{example1}{color=red} \useMPgraphic{example2}{color=red} \s

Re: [NTG-context] \startuseMPgraphic

2016-04-11 Thread Meer, Hans van der
{color}; \stopuseMPgraphic \useMPgraphic{example1}{color=red} \useMPgraphic{example2}{color=red} \stoptext mpcolor.pdf Description: mpcolor.pdf ___ If your question is of interest to others as well, please add an entry

Re: [NTG-context] \startuseMPgraphic

2016-04-11 Thread Meer, Hans van der
default value to that variable, possibly to be overridden with \useMPgraphic{name}{key=value}. I very much would like to specify default values on the \startuseMPgraphic definition of the graphic. However, I cannot get option (2) working. Do I have a bad memory (possible of course ;-), Has i

[NTG-context] \startuseMPgraphic

2016-04-11 Thread Jeong Dal
square scaled 1cm withcolor \MPvar{color}; > \stopuseMPgraphic > > \useMPgraphic{myname1}{color=blue} > \useMPgraphic{myname2}{color=orange} > > \stoptext > > Hans van der Meer > ___ If

Re: [NTG-context] \startuseMPgraphic

2016-04-11 Thread Wolfgang Schuster
se one is able to set a default value to that variable, possibly to be overridden with \useMPgraphic{name}{key=value}. I very much would like to specify default values on the \startuseMPgraphic definition of the graphic. However, I cannot get option (2) working. Do I have a bad memory (possi

[NTG-context] \startuseMPgraphic

2016-04-11 Thread Meer, Hans van der
overridden with \useMPgraphic{name}{key=value}. I very much would like to specify default values on the \startuseMPgraphic definition of the graphic. However, I cannot get option (2) working. Do I have a bad memory (possible of course ;-), Has it to be done otherwise? In the example below the graphic

Re: [NTG-context] Setting expansion depth limit for metapost

2016-02-18 Thread Hans Hagen
rking example of this problem I isolated it in the process. There were 3 MP graphics each one used once on each page. After change them from \startuseMPgraphic ... \stopuseMPgraphic and \useMPgraphic to \startreusableMPgraphic ... \stopreusableMPgraphic and \useMPgraphic error messages disapp

Re: [NTG-context] Setting expansion depth limit for metapost

2016-02-18 Thread Michal Suszko
isolated it in the process. There were 3 MP graphics each one used once on each page. After change them from \startuseMPgraphic ... \stopuseMPgraphic and \useMPgraphic to \startreusableMPgraphic ... \stopreusableMPgraphic and \useMPgraphic error messages disappe

Re: [NTG-context] How to put title and counter of the enumeration env. in the FrameTitle?

2015-12-08 Thread Jeong Dal
black ; setbounds currentpicture to a ; \stopuseMPgraphic \defineoverlay[FunnyFrame][\useMPgraphic{FunnyFrame}] \defineframedtext[Thm] [frame=off, background=FunnyFrame, offset=\bodyfontsize, %increment=yes, width=\textwidth, before={\blank[big]}, after={\incrementnumber[ThmNumber]\blank

Re: [NTG-context] How to put title and counter of the enumeration env. in the FrameTitle?

2015-12-04 Thread Jeong Dal
) ; b := a superellipsed .95 ; draw b ; b := (boundingbox p) superellipsed .95 ; fill b withcolor .85white ; draw b ; draw p withcolor black ; setbounds currentpicture to a ; \stopuseMPgraphic \defineoverlay[FunnyFrame][\useMPgraphic{FunnyFrame}] \defineframedtext[Thm] [frame=off

[NTG-context] How to put title and counter of the enumeration env. in the FrameTitle?

2015-12-03 Thread Jeong Dal
; \stopuseMPgraphic \defineoverlay[FunnyFrame][\useMPgraphic{FunnyFrame}] \defineframedtext[FunnyText][frame=off,background=FunnyFrame, offset=\bodyfontsize, width=\textwidth]%\overlaywidth]% \def\StTheorem{\startFunnyText\startTheorem} \def\SpTheorem {\stopTheorem\stopFunnyText } \def

Re: [NTG-context] Loop and graphictext (Metafun)

2015-10-05 Thread Fabrice Couvreur
extcolor} ; >>>> \stopMPinclusions >>>> >>>> \setMPtext{title}{Serie statistiques à deux variables} >>>> >>>> \startuseMPgraphic{Title} >>>> >>>>path p ; p := OverlayBox ; >>>>fill OverlayBox withcolor pagecolor

Re: [NTG-context] Loop and graphictext (Metafun)

2015-10-05 Thread Fabrice Couvreur
r textcolor ; textcolor := \MPcolor{textcolor} ; >>> \stopMPinclusions >>> >>> \setMPtext{title}{Serie statistiques à deux variables} >>> >>> \startuseMPgraphic{Title} >>> >>>path p ; p := OverlayBox ; >>>fill OverlayB

Re: [NTG-context] Loop and graphictext (Metafun)

2015-10-05 Thread Fabrice Couvreur
>>path p ; p := OverlayBox ; >>fill OverlayBox withcolor pagecolor ; >>setbounds currentpicture to OverlayBox ; >> >> \stopuseMPgraphic >> >> \defineoverlay[Title][\useMPgraphic{Title}] >> >> \defineframedtext >>[MyTitle] >

Re: [NTG-context] Loop and graphictext (Metafun)

2015-10-05 Thread Hans Hagen
currentpicture to OverlayBox ; \stopuseMPgraphic \defineoverlay[Title][\useMPgraphic{Title}] \defineframedtext [MyTitle] [before={\blank[line,halfline]}, after={\blank}, frame=off, background=Title, width=\textwidth, height=fit, ] \starttext \startMyTitle \startMPcode

[NTG-context] Loop and graphictext (Metafun)

2015-10-05 Thread Fabrice Couvreur
\defineoverlay[Title][\useMPgraphic{Title}] \defineframedtext [MyTitle] [before={\blank[line,halfline]}, after={\blank}, frame=off, background=Title, width=\textwidth, height=fit, ] \starttext \startMyTitle \startMPcode numeric k ; k :=0 ; string s ; s := \MPstring{title} ; picture r

[NTG-context] Center text in an image (Metafun)

2015-09-13 Thread Fabrice Couvreur
00, k=0.05] \definecolor[MyColorD][c=0.6, m=0.00, y=0.00, k=0.10] \definemixedcolumns [myColumn] [n=2, separator=rule, rulecolor=MyColorC, rulethickness=1pt, maxwidth=\availablehsize, balance=yes] \setupalign[verytolerant,stretch,hanging] \defineoverlay [Funny] [\useMPgra

Re: [NTG-context] Space between both environments

2015-09-08 Thread Fabrice Couvreur
y=0.00, k=0.10] > > > \defineframedtext > [MyDefinition] > [before={\blank}, >after={\blank}, >frame=off, >background=MyFrame, >width=\textwidth, >height=fit, >location=left, >style=italic] > > \defineoverlay > [MyFrame]

Re: [NTG-context] Space between both environments

2015-09-07 Thread Wolfgang Schuster
defineframedtext [MyDefinition] [before={\blank}, after={\blank}, frame=off, background=MyFrame, width=\textwidth, height=fit, location=left, style=italic] \defineoverlay [MyFrame] [\useMPgraphic{MyFrame}] \definelabel [Définition] [headstyle=\bf\smallcaps] \startuseM

Re: [NTG-context] Space between both environments

2015-09-07 Thread Otared Kavian
after={\blank}, >frame=off, >background=MyFrame, >width=\textwidth, >height=fit, >location=left, >style=italic] > > \defineoverlay > [MyFrame] > [\useMPgraphic{MyFrame}] > > \definelabel > [Définition] > [headstyle=\bf\smallcaps]

[NTG-context] Space between both environments

2015-09-07 Thread Fabrice Couvreur
] \definecolor[MyColorD][c=0.6, m=0.00, y=0.00, k=0.10] \defineframedtext [MyDefinition] [before={\blank}, after={\blank}, frame=off, background=MyFrame, width=\textwidth, height=fit, location=left, style=italic] \defineoverlay [MyFrame] [\useMPgraphic{MyFrame}] \definelabel

[NTG-context] Bug with the command \blank ?

2015-08-30 Thread Fabrice Couvreur
[MyFrame] [\useMPgraphic{MyFrame}] \definelabel [Définition] [headstyle=\bf\smallcaps] \startuseMPgraphic{MyFrame} path b ; picture p ; p := textext.rt("\white\Définition") ; p := p shifted (2BodyFontSize,OverlayHeight-ypart center p+.25ExHeight) ; b := bou

Re: [NTG-context] Left border of a rectangle (Metafun)

2015-08-29 Thread Otared Kavian
> middle. > Why ? > Thank you, > Fabrice > > \setupcolors[state=start] > > > \definecolor[MyColorA][c=0.3, m=0.00, y=0.00, k=0.05] > > > > \defineoverlay > [Funny] > [\useMPgraphic{Funny}] > > \startuseMPgraphic{Funny} > interim linecap

Re: [NTG-context] Left border of a rectangle (Metafun)

2015-08-29 Thread Otared Kavian
0.05] > > > > \defineoverlay > [Funny] > [\useMPgraphic{Funny}] > > \startuseMPgraphic{Funny} > interim linecap := butt ; > path p ; > p := unitsquare xyscaled (OverlayWidth,OverlayHeight) ; > drawoptions (withpen pencircle sca

[NTG-context] Left border of a rectangle (Metafun)

2015-08-29 Thread Fabrice Couvreur
Hi, I want to draw the left border of the rectangle, but it is drawn in the middle. Why ? Thank you, Fabrice \setupcolors[state=start] \definecolor[MyColorA][c=0.3, m=0.00, y=0.00, k=0.05] \defineoverlay [Funny] [\useMPgraphic{Funny}] \startuseMPgraphic{Funny} interim linecap

[NTG-context] Cover page (Metafun)

2015-08-14 Thread Fabrice Couvreur
color) ; draw q withpen pencircle scaled 8pt withcolor darkcolor ; endfor ; endfor ; \stopuseMPgraphic \defineoverlay[CoverPage][\useMPgraphic{CoverPage}] \setupbackgrounds [rightpage] [background=Cov

Re: [NTG-context] Text around a figure in a framedtext

2015-08-14 Thread Fabrice Couvreur
location=left, >style=italic] > > \defineoverlay > [MyFrame] > [\useMPgraphic{MyFrame}] > > \definelabel > [Définition] > [headstyle=\bf\smallcaps] > > \startuseMPgraphic{MyFrame} > path b ; > picture p ; > p := textext.rt("\white\Définiti

Re: [NTG-context] Text around a figure in a framedtext

2015-08-13 Thread Rik Kabel
[MyColorA][.75(MyColorB,white)] \defineframedtext [MyText] [frame=off, background=MyFrame, width=\textwidth, height=fit, location=left, style=italic] \defineoverlay [MyFrame] [\useMPgraphic{MyFrame}] \definelabel [Définition] [headstyle=\bf\smallcaps] \startuseMPgraphic

Re: [NTG-context] Text around a figure in a framedtext

2015-08-13 Thread Fabrice Couvreur
>height=fit, >location=left, >style=italic] > > \defineoverlay > [MyFrame] > [\useMPgraphic{MyFrame}] > > \definelabel > [Définition] > [headstyle=\bf\smallcaps] > > \startuseMPgraphic{MyFrame} > path b ; > picture p ; > p :

Re: [NTG-context] Text around a figure in a framedtext

2015-08-13 Thread Fabrice Couvreur
[MyText] [frame=off, background=MyFrame, width=\textwidth, height=fit, location=left, style=italic] \defineoverlay [MyFrame] [\useMPgraphic{MyFrame}] \definelabel [Définition] [headstyle=\bf\smallcaps] \startuseMPgraphic{MyFrame} path b ; picture p ; p

Re: [NTG-context] Text around a figure in a framedtext

2015-08-08 Thread Fabrice Couvreur
definecolor[MyColorB][c=0.00, m=0.62, y=1.00, k=0.00] > > \definecolor[MyColorA][.75(MyColorB,white)] > > > > \defineframedtext > > [MyText] > > [frame=off, > >background=MyFrame, > >width=\textwidth, > >location=right] > > > > \defineov

Re: [NTG-context] Text around a figure in a framedtext

2015-08-07 Thread Otared Kavian
efinecolor[MyColorA][.75(MyColorB,white)] > > \defineframedtext > [MyText] > [frame=off, >background=MyFrame, >width=\textwidth, >location=right] > > \defineoverlay > [MyFrame] > [\useMPgraphic{MyFrame}] > > \definelabel >

[NTG-context] Text around a figure in a framedtext

2015-08-07 Thread Fabrice Couvreur
, location=right] \defineoverlay [MyFrame] [\useMPgraphic{MyFrame}] \definelabel [Définition] [headstyle=\bf\smallcaps] \startuseMPgraphic{MyFrame} path b ; picture p ; p := textext.rt("\white\Définition") ; p := p shifted (2BodyFontSize,OverlayHeight-ypart center p+.

Re: [NTG-context] Some questions about an environment (Metafun)

2015-08-07 Thread Fabrice Couvreur
olor][c=0.00, m=0.10, y=0.20, k=0.00] >> \definecolor[myColor][c=0.00, m=0.62, y=1.00, k=0.00] >> >> \defineoverlay[MyFrame][\useMPgraphic{MyFrame}] >> >> \defineframedtext >> [MyText] >> [frame=off, >> background=MyFrame, >> width=\tex

Re: [NTG-context] Some questions about an environment (Metafun)

2015-08-07 Thread Hans Hagen
, k=0.00] \defineoverlay[MyFrame][\useMPgraphic{MyFrame}] \defineframedtext [MyText] [frame=off, background=MyFrame, width=\textwidth, location=right] \defineoverlay[MyFrame][\useMPgraphic{MyFrame}] \def\StartFrame{\startMyText} \def\StopFrame{\startMyText} \def\FrameTitle

Re: [NTG-context] Some questions about an environment (Metafun)

2015-08-06 Thread Fabrice Couvreur
][\useMPgraphic{MyFrame}] \defineframedtext [MyText] [frame=off, background=MyFrame, width=\textwidth, location=right] \defineoverlay[MyFrame][\useMPgraphic{MyFrame}] \def\StartFrame{\startMyText} \def\StopFrame{\startMyText} \def\FrameTitle#1{\setMPtext{MyFrame}{\hbox spread 1em{\hss\strut

Re: [NTG-context] Some questions about an environment (Metafun)

2015-08-04 Thread Fabrice Couvreur
or} ; > draw p withcolor white ; > setbounds currentpicture to OverlayBox ; > \stopuseMPgraphic > > > > Thank you, >> Fabrice >> >> \showframe >> >> \setupcolors[state=start,cmyk=yes] >> >> \definecolor[MyColor][c=0.00, m=0.10, y=0.

Re: [NTG-context] Some questions about an environment (Metafun)

2015-08-04 Thread Hans Hagen
\setupcolors[state=start,cmyk=yes] \definecolor[MyColor][c=0.00, m=0.10, y=0.20, k=0.00] \definecolor[myColor][c=0.00, m=0.62, y=1.00, k=0.00] \setupbodyfont[11pt] \defineoverlay[MyFrame][\useMPgraphic{MyFrame}] \defineframedtext [MyText] [frame=off, background=MyFrame, width=0.9

[NTG-context] Some questions about an environment (Metafun)

2015-08-04 Thread Fabrice Couvreur
=0.62, y=1.00, k=0.00] \setupbodyfont[11pt] \defineoverlay[MyFrame][\useMPgraphic{MyFrame}] \defineframedtext [MyText] [frame=off, background=MyFrame, width=0.9\textwidth, location=right] \defineoverlay[MyFrame][\useMPgraphic{MyFrame}] \def\StartFrame{\startMyText} \def

Re: [NTG-context] Frame and rulethickness

2015-03-28 Thread Wolfgang Schuster
withcolor \MPcolor{green} ; clip currentpicture to OverlayBox leftenlarged 1pt rightenlarged 1.5pt bottomenlarged 0.5pt ; \stopuseMPgraphic \defineoverlay[ACFRAME][\useMPgraphic{ACFRAME}] \defineframed [ACFRAME] [frame=off, background=ACFRAME] \starttext \ACFRAME{ Example } \sto

Re: [NTG-context] Update text variables inside metapost

2015-03-08 Thread Hans Hagen
}{text2}{text3}, 2. and four \Bolha[size=4cm]{text1}{text2}{text3}, but text1, text2 and text3 is not updated in every call; Use useMPgraphic instead of uniqueMPgraphic. uniqueMPgraphic recomputes the graphic only when the dimensions of figure has changed; otherwise, it reuses the previously drawn

Re: [NTG-context] Update text variables inside metapost

2015-03-07 Thread DesdeChaves
t;> >> In the code below, If I have \startitemize[columns,two] then metapost >> draw: >> >> 1. \Bolha[size=6cm]{text1}{text2}{text3}, >> 2. and four \Bolha[size=4cm]{text1}{text2}{text3}, but text1, text2 and >> text3 is not updated in every call; >>

Re: [NTG-context] Update text variables inside metapost

2015-03-07 Thread Aditya Mahajan
]{text1}{text2}{text3}, but text1, text2 and text3 is not updated in every call; Use useMPgraphic instead of uniqueMPgraphic. uniqueMPgraphic recomputes the graphic only when the dimensions of figure has changed; otherwise, it reuses the previously drawn graphic. This behavior was useful for

[NTG-context] Update text variables inside metapost

2015-03-07 Thread DesdeChaves
\def\Bolha[#1]#2#3#4% {\setupMPvariables[bolha][#1]% \setMPtext{labelcima}{#3}% \setMPtext{labelesquerda}{#2}% \setMPtext{labeldireita}{#4}% \useMPgraphic{bolha}} \startuniqueMPgraphic{bolha} path p, q, cima, esquerda, direita, vertical; pair A, B, C; p:=fullcircle scaled \MPvar{size}; A

[NTG-context] How to place text to the right of a brace

2015-02-01 Thread Fabrice Couvreur
e[height=\overlayheight]{\useMPgraphic{accolade}}}] \defineoverlay[rightbrace][\rightaligned{\mirror{\scale[height=\overlayheight]{\useMPgraphic{accolade] \starttext \framedtext[frame=off,loffset=1em,roffset=1em,background={rightbrace}]{ La longueur est \unit{4 centimeter} ; on donne

[NTG-context] Problems with repeating layers

2014-12-07 Thread Reza Housseini
currentpicture) ; \stopuseMPgraphic \setMPlayer [test] [somepos-1] {\externalfigure[cow][width=2cm]} \getMPlayer [test] {\useMPgraphic{oeps}} but that does not seem to work at all. Thanks for any help Cheers, Reza ___

[NTG-context] Strange behavior of a macro with ConTeXt ver : 2014.11.12 9:46 p.m. MKIV beta

2014-11-15 Thread Fabrice Couvreur
Hi, Macro written by Hans does not work. Best regards, Fabrice % macros=mkvi \starttext \starttexdefinition MyOtherHeader #where #day #month #year #title \defineoverlay[whatever][\useMPgraphic{whatever}] \startuseMPgraphic{whatever} path p; p:=fullsquare xyscaled (\overlaywidth

Re: [NTG-context] Create an item marker with a counter with Metapost

2014-11-10 Thread Aditya Mahajan
xyscaled (u,u) randomized 2pt; pickup pencircle scaled 1pt; fill p withcolor green; draw p withcolor blue; \stopuseMPgraphic \definesymbol[itemize:fuzzy][\useMPgraphic{itemize:fuzzy}] \setupitemize[1][symbol=itemize:fuzzy] \starttext \startitemize \item \input knuth \item \input knuth \stopitemize

Re: [NTG-context] Create an item marker with a counter with Metapost

2014-11-10 Thread Wolfgang Schuster
circle xyscaled (u,u) randomized 2pt; > pickup pencircle scaled 1pt; > fill p withcolor green; > draw p withcolor blue; > \stopuseMPgraphic > \definesymbol[itemize:fuzzy][\useMPgraphic{itemize:fuzzy}] > \setupitemize[1][symbol=itemize:fuzzy] > \starttext > \startitem

Re: [NTG-context] Create an item marker with a counter with Metapost

2014-11-10 Thread Alan BRASLAU
imal counter) withcolor red; counter := counter + .5; \stopuseMPgraphic \definesymbol[itemize:fuzzy][\useMPgraphic{itemize:fuzzy}] \setupitemize[1][symbol=itemize:fuzzy] \starttext \startitemize \startitem \input knuth \stopitem \startitem \input knuth \stopitem \stopitemi

[NTG-context] Create an item marker with a counter with Metapost

2014-11-10 Thread Fabrice Couvreur
; \stopuseMPgraphic \definesymbol[itemize:fuzzy][\useMPgraphic{itemize:fuzzy}] \setupitemize[1][symbol=itemize:fuzzy] \starttext \startitemize \item \input knuth \item \input knuth \stopitemize \stoptext ___ If your

Re: [NTG-context] \startanimation and \dorecurse

2014-10-22 Thread Jeong Dal
) of p;% draw q withcolor red; fill fullcircle scaled 3 shifted point length q of q withcolor blue; setbounds currentpicture to unitsquare shifted (-0.5,-0.5) scaled 75; \stopuseMPgraphic \starttext \startanimation[menu=yes, menucolor=blue, framerate=5] \dorecurse{20} {\expanded{\frame{ \useMPgraphic

Re: [NTG-context] \startanimation and \dorecurse

2014-10-21 Thread Wolfgang Schuster
blue; > setbounds currentpicture to unitsquare shifted (-0.5,-0.5) scaled 75; > \stopuseMPgraphic > \starttext > \startanimation > \dorecurse{20} > {\startexpanded > %\setupMPvariables[Circles][s] > \useMPgraphic{Circles}{s=\recurselevel} > \stopexpanded} > \stopanimati

Re: [NTG-context] \startanimation and \dorecurse

2014-10-21 Thread Jeong Dal
%\setupMPvariables[Circles][s] \useMPgraphic{Circles}{s=\recurselevel} \stopexpanded} \stopanimation \stoptext %% However, it just draw 20 figures instead of making an animation. Would you please tell me what is wrong in the above code? Thank you. Best regards, Dalyoung

Re: [NTG-context] \startanimation and \dorecurse

2014-10-20 Thread Wolfgang Schuster
s} numeric u; u:= 1cm; draw fullcircle scaled \MPvar{s}u; \stopuseMPgraphic \starttext \startanimation \dorecurse{5} {\startexpanded \frame{\useMPgraphic{Circles}{s=\recurselevel}}% \stopexpanded} \stopanimation \stoptext Wolfgang __

Re: [NTG-context] Metafun error

2014-09-27 Thread Willi Egger
Sep 2014, at 15:17, Willi Egger wrote: >>> >>>> Hello! >>>> >>>> Today I wanted to use an older tex file…. I get the same error as in the >>>> following test. >>>> >>>> \startun

Re: [NTG-context] Metafun error

2014-09-26 Thread Otared Kavian
;> >>> Hello! >>> >>> Today I wanted to use an older tex file…. I get the same error as in the >>> following test. >>> >>> \startuniqueMPgraphic{test} >>> >>> path p; >>> p := fullcircle scaled 5cm

Re: [NTG-context] Metafun error

2014-09-26 Thread Willi Egger
. I get the same error as in the >> following test. >> >> \startuniqueMPgraphic{test} >> >> path p; >> p := fullcircle scaled 5cm; >> draw p; >> label.bot(textext("Centre"), center p); >>

Re: [NTG-context] Metafun error

2014-09-26 Thread Otared Kavian
tex file…. I get the same error as in the > following test. > > \startuniqueMPgraphic{test} > > path p; > p := fullcircle scaled 5cm; > draw p; > label.bot(textext("Centre"), center p); > > \stopuniqueMPgraphic >

[NTG-context] Metafun error

2014-09-26 Thread Willi Egger
\starttext \startTEXpage \useMPgraphic{test} \stopTEXpage \stoptext The error message is: Argument of \meta_start_environment has an extra } \par } \meta_handle_unique_graphic ...ocess_graphic {#3}} \setxvalue {\??mpgraphic \... \meta_u

Re: [NTG-context] internal mptopdf converter skips some glyphs in labels

2014-06-05 Thread Hans Hagen
lose the other factor of 3 (3^2=10), and maybe more.) That is only true if you can produce content at high speed -) Otherwise the ratio typing - thinking - making up text etc is not that good. Are you sure' it's 'much' longer? You can still put graphics in external files, or us

Re: [NTG-context] passing arguments to \processMPbuffer

2014-04-21 Thread Wolfgang Schuster
& decimal (i) & "}$" ), \MPvar{s}[origin,3u*dir(30*i)]) > ; > label (textext("$v_{" & decimal (i) & "}$" ), \MPvar{t}[origin,3u*dir(30*i)]) > ; > endfor; > \stopuseMPgraphic > > \starttext > \placefigure[][]{} >

[NTG-context] passing arguments to \processMPbuffer

2014-04-21 Thread Jeong Dal
(textext("$v_{" & decimal (i) & "}$" ), \MPvar{t}[origin,3u*dir(30*i)]) ; endfor; \stopuseMPgraphic \starttext \placefigure[][]{} {\useMPgraphic{ColoringFace::Labeling}{s=0.8, t=1.3}} \stoptext Is there a way to the same job for \processMPbuffer instead of .5 and

[NTG-context] textcolor not working with MPinstance

2014-04-15 Thread Aditya Mahajan
w textext("some text") ; \stopMPcode % a graphic that uses a custom instance % This does not work with the current stable version \startuseMPgraphic{veryimportant::mygraphic} draw textext("some text") ; \stopuseMPgraphic \useMPgraphic{veryimportant

Re: [NTG-context] Metapost: I only need a little bit padding

2014-04-05 Thread Peter Rolf
urrentpicture rotated 90; > \stopuseMPgraphic > > > \starttext > \useMPgraphic{rotatedHeadline} > \stoptext Best wishes, Peter ___ If your question is of interest to others as well, please add an entry

[NTG-context] Metapost: I only need a little bit padding

2014-04-05 Thread Jan Heinen
currentpicture := currentpicture rotated 90; \stopuseMPgraphic \starttext \useMPgraphic{rotatedHeadline} \stoptext ___ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-contex

Re: [NTG-context] MP bounding box

2014-03-12 Thread Peter Rolf
[..] >>>> >>>> e >>>> e >>>>- >>>> 6.103515625e- >>>>005 >>>> \setMPboundingbox #1#2#3#46-\global \MPllx #1 >>>>\onebasepoint \global >>>> \MPlly #2... >>>> \startMPLI

Re: [NTG-context] MP bounding box

2014-03-12 Thread Hans Hagen
3}{#4} \setbox \MPbox \vbox \bgro... l.13 } l.50 \useMPgraphic{path:ivy} ! ==> Fatal error occurred, no output PDF file produced! mtx-context | fatal error: return code: 1 [fin] catched in next beta Thanks. Time to update my antique version (12/2013). not yet

Re: [NTG-context] MP bounding box

2014-03-12 Thread Peter Rolf
\onebasepoint \global >> \MPlly #2... >> \startMPLIBtoPDF ...MPboundingbox {#1}{#2}{#3}{#4} >>\setbox \MPbox \vbox >> \bgro... >> l.13 } >> >> >> l.50 \useMPgraphic{path:ivy} >> >> ! ==> Fatal error occu

Re: [NTG-context] MP bounding box

2014-03-12 Thread Hans Hagen
005 \setMPboundingbox #1#2#3#46-\global \MPllx #1 \onebasepoint \global \MPlly #2... \startMPLIBtoPDF ...MPboundingbox {#1}{#2}{#3}{#4} \setbox \MPbox \vbox \bgro... l.13 } l.50 \useMPgraphic{path:ivy} ! ==&g

[NTG-context] MP bounding box

2014-03-12 Thread Peter Rolf
lx #1 \onebasepoint \global \MPlly #2... \startMPLIBtoPDF ...MPboundingbox {#1}{#2}{#3}{#4} \setbox \MPbox \vbox \bgro... l.13 } ... l.50 \useMPgraphic{path:ivy} ! ==> Fatal error occurred, no output PDF file produ

[NTG-context] Problem with an environment

2014-03-06 Thread Fabrice Couvreur
title #number \defineoverlay[whatever][\useMPgraphic{whatever}] \startuseMPgraphic{whatever} path p; p:=fullsquare xyscaled (\overlaywidth,\overlayheight) squeezed 1pt; fill p withcolor white ; draw p withpen pencircle scaled 2pt withcolor 0.625white ; picture d ; d := textext("\quad#w

Re: [NTG-context] New header

2014-01-20 Thread Hans Hagen
x file with this line: % macros=mkvi \starttext \starttexdefinition MyOtherHeader #where #day #month #year #title #number \defineoverlay[whatever][\useMPgraphic{whatever}] \startuseMPgraphic{whatever} draw OverlayBox withpen pencircle scaled .5pt da

Re: [NTG-context] Code Called Twice?

2013-10-11 Thread Philipp Gesang
ThemeTitleStyle} > >>show "HEADING:THEMETITLESTYLE"; > >>show \MPstring{heading:title}; > >> > >>draw textext( \MPstring{heading:title} ) rotated 5 > >> withcolor blue; > >> \stopuseMPgraphic > >> > >> \d

<    1   2   3   4   5   6   7   8   9   10   >