Thanks Hans
Fabrice
2017-05-27 0:09 GMT+02:00 Hans Hagen
On 5/26/2017 12:53 PM, Fabrice Couvreur wrote:
Hello, Hans suggested a macro to draw the vectors . It works well but I find that in some situations, the arrow is too big. thank you,
interim ahlength := 2;
Fabrice
https://mailman.ntg.nl/pipermail/ntg-context/2016/085828.html
\useMPlibrary[mat]
\startMPextensions vardef math_stacker_arrow_shape = image ( drawarrow (OverlayWidth,OverlayOffset) -- (0,OverlayOffset) withcolor OverlayLineColor ; setbounds currentpicture to boundingbox currentpicture bottomenlarged (OverlayOffset/2) topenlarged (OverlayOffset/2) ; ) enddef ; vardef math_stacker_leftarrow_shape = math_stacker_arrow_shape enddef ; vardef math_stacker_rightarrow_shape = math_stacker_arrow_shape rotated 180 enddef ; \stopMPextensions
\startuniqueMPgraphic{math:stacker:\number"2190} math_stacker_draw(math_stacker_leftarrow_shape) ; \stopuniqueMPgraphic
\startuniqueMPgraphic{math:stacker:\number"2192} math_stacker_draw(math_stacker_rightarrow_shape) ; \stopuniqueMPgraphic
% so far
\setupmathstackers [both] % vfenced] [color=darkred, alternative=mp]
\setupmathstackers [top] [color=darkred, alternative=mp]
\setupmathstackers [bottom] [color=darkred, alternative=mp]
\starttext
$\overrightarrow {i}$
\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.ntg.nl/mailman/list info/ntg-context webpage : http://www.pragma-ade.nl / http://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ____________________________________________________________ _______________________
--
----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl ----------------------------------------------------------------- ____________________________________________________________ _______________________ If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/list info/ntg-context webpage : http://www.pragma-ade.nl / http://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ____________________________________________________________ _______________________