Re: [NTG-context] bottlenecks

2022-12-18 Thread mf via ntg-context
, 4 common vectors, 12 common hashes, load time 0.148 seconds mkiv lua stats  > text directions: 5.911 seconds mkiv lua stats  > metapost: 1.180 seconds, loading: 0.083, execution: 1.109, n: 1039, average: 0.002, instances: 2, luacalls: 46885 (file: 34713, text: 0, script: 5932, log: 6240)

Re: [NTG-context] bottlenecks

2022-12-18 Thread mf via ntg-context
iboldit.otf, quivira.otf, sileot.ttf mkiv lua stats  > font engine: otf 3.131, afm 1.513, tfm 1.000, 533 instances, 501 shared in backend, 6 common vectors, 495 common hashes, load time 0.196 seconds mkiv lua stats  > text directions: 5.754 seconds mkiv lua stats  > metapost: 1.18

Re: [NTG-context] Mathematical MetaFun Mania

2022-12-18 Thread Alexandre Christe via ntg-context
re put there), but for the upper bounds, the \infty > and \pi/2 are not accepted (nor is any letter or greek symbol), but if one > replaces \infty and \pi/2 with numbers, then the link between the upper > bounds is shown. (In this example the links are invading the text, but > probably this

Re: [NTG-context] bottlenecks

2022-12-17 Thread Hans Hagen via ntg-context
On 12/17/2022 10:11 PM, Alan Braslau via ntg-context wrote: With lots of MetaPost, lots of references, lots of figures, lots of tables, lots of bibliography entries, lots of chemical structures, ... mkiv lua stats > node memory usage: 2491 attribute, 76 boundary, 84 dir, 1167 glue,

Re: [NTG-context] bottlenecks

2022-12-17 Thread Alan Braslau via ntg-context
With lots of MetaPost, lots of references, lots of figures, lots of tables, lots of bibliography entries, lots of chemical structures, ... mkiv lua stats > used config file: selfautoparent:/texmf/web2c/texmfcnf.lua mkiv lua stats > used cache path: /home/braslau/context/beta/tex/texmf

Re: [NTG-context] bottlenecks

2022-12-16 Thread Henning Hraban Ramm via ntg-context
ed in backend, 11 common vectors, 146 common hashes, load time 15.349 seconds mkiv lua stats > body font sizes: defined: 10pt 11pt 12pt 14.4pt 17.3pt 20.7pt 4pt 5pt 6pt 7pt 8pt 9pt, undefined: 11.2pt 14pt 16.8pt mkiv lua stats > visualization time: 0.154 seconds mkiv lua stats > metapost:

Re: [NTG-context] Mathematical MetaFun Mania

2022-12-16 Thread Hans Hagen via ntg-context
to the fact that I just copied the Metapost snippet you sent to Gavin). you can pick up a binary with a safeguard from https://build.contextgarden.net/#/waterfall?tags=c.luametatex (or compile one yourself from work) Hans

Re: [NTG-context] Mathematical MetaFun Mania

2022-12-16 Thread Hans Hagen via ntg-context
to the fact that I just copied the Metapost snippet you sent to Gavin). temp solution: \setmathoptions\mathordinarycode\numexpr \noitaliccorrectionclassoptioncode +\checkkernpairclassoptioncode % +\flattenclassoptioncode \relax something MS and i need to discuss probably (read: if this old

Re: [NTG-context] Mathematical MetaFun Mania

2022-12-15 Thread Otared Kavian via ntg-context
are not accepted (nor is any letter or greek symbol), but if one replaces \infty and \pi/2 with numbers, then the link between the upper bounds is shown. (In this example the links are invading the text, but probably this is due to the fact that I just copied the Metapost snippet you sent

Re: [NTG-context] Mathematical MetaFun Mania

2022-12-15 Thread Hans Hagen via ntg-context
On 12/15/2022 5:15 PM, Gavin wrote: Hi Hans and List, 2) Can I tell \connectboxanchors to use my MetaPost code and pass key=value pairs like I do with \setMPpositiongraphic? see attached ... the 'cross pages' feature is in the upcoming This indeed passes key=value pairs, but I cannot get

Re: [NTG-context] Mathematical MetaFun Mania

2022-12-15 Thread Gavin via ntg-context
Hi Hans and List, >> 2) Can I tell \connectboxanchors to use my MetaPost code and pass key=value >> pairs like I do with \setMPpositiongraphic? > see attached ... the 'cross pages' feature is in the upcoming This indeed passes key=value pairs, but I cannot get it to pass mine.

Re: [NTG-context] Mathematical MetaFun Mania

2022-12-15 Thread Hans Hagen via ntg-context
\mathboxanchored and \connectboxanchors to my MetaPost code. Here is the code for the connectors: \startMPpositiongraphic{mypos:contract} path pa, pb, pab ; numeric na, nb ; string ta, tb, hand, product ; ta := mpvars("from") ; tb := mpvars("to") ; stemshiftfrom := (EmWidth/

[NTG-context] Mathematical MetaFun Mania

2022-12-14 Thread Gavin via ntg-context
, but it is all working. Right now the interface is terrible, but effective. Thanks to Hans and Mikael for many helpful hints! I am still using \hpos and \setMPpositiongraphic, because I haven't figured out how to pass information from \mathboxanchored and \connectboxanchors to my MetaPost code. Here

Re: [NTG-context] Radial and linear gradients

2022-12-14 Thread Hans Hagen via ntg-context
On 12/14/2022 9:45 PM, Thangalin via ntg-context wrote: Inkscape can export the gradients to PDF. I was hoping to eliminate Inkscape as an extra piece of software users have to download to make sure their SVG images are rendered correctly. By containerizing ConTeXt, MetaPost can be swapped

Re: [NTG-context] Radial and linear gradients

2022-12-14 Thread Thangalin via ntg-context
Inkscape can export the gradients to PDF. I was hoping to eliminate Inkscape as an extra piece of software users have to download to make sure their SVG images are rendered correctly. By containerizing ConTeXt, MetaPost can be swapped for Inkscape, so users won't even know. It is, however

Re: [NTG-context] Radial and linear gradients

2022-12-14 Thread Hans Hagen via ntg-context
On 12/14/2022 5:46 AM, Thangalin via ntg-context wrote: Hi there! Any thoughts on implementing SVG gradients in MetaPost? % SOF \startbuffer[csvg] http://www.w3.org/2000/svg; xmlns:xlink="http://www.w3.org/1999/xlink; viewBox="0 0 115.669 115.669"> \stopbuffer \startte

[NTG-context] Radial and linear gradients

2022-12-13 Thread Thangalin via ntg-context
Hi there! Any thoughts on implementing SVG gradients in MetaPost? % SOF \startbuffer[csvg] http://www.w3.org/2000/svg; xmlns:xlink="http://www.w3.org/1999/xlink; viewBox="0 0 115.669 115.669"> \stopbuffer \starttext \placefigure{}{\includesvgbuffer[csvg][conversion=mp]} \s

Re: [NTG-context] Is this possible to do the same

2022-12-12 Thread Ursula Hermann via ntg-context
.~$\cancel{x+ {-x}}$. Works in \cancel{text}, too. \stoptext I do not have all of the features of the “cancel” package, but it works for a simple cross out. Change the MetaPost code to a single slash, if that is what you want, by removing either one of the draw commands. Hope that helps. If you need

Re: [NTG-context] Is this possible to do the same

2022-12-12 Thread Gavin via ntg-context
\dots E.g.~$\cancel{x+ {-x}}$. Works in \cancel{text}, too. \stoptext I do not have all of the features of the “cancel” package, but it works for a simple cross out. Change the MetaPost code to a single slash, if that is what you want, by removing either one of the draw commands. Hope that helps

Re: [NTG-context] \hpos in math

2022-12-06 Thread Hans Hagen via ntg-context
networks of connections above and below many formulas. The integration of TeX, MetaPost, and Lua makes this project tremendous fun. that's the idea P.S. For the curious, I’m using a method for doing General Relativity based on spinors rather than tensors, following the methods of Penrose

[NTG-context] \hpos in math

2022-12-05 Thread Gavin via ntg-context
amazing tool for this project, which includes complicated networks of connections above and below many formulas. The integration of TeX, MetaPost, and Lua makes this project tremendous fun. Thanks! Gavin P.S. For the curious, I’m using a method for doing General Relativity based on spinors

Re: [NTG-context] annotated equations

2022-11-18 Thread Hans Hagen via ntg-context
with node anchors in ConTeXt/MetaPost? Yes, this is possible using node anchors and \hpos etc. The interface is slightly cumbersome, mainly because you have to make sure that anchors are unique. I sometimes use such constructs in my presentations, but not often enough to build a nice interface

Re: [NTG-context] annotated equations

2022-11-18 Thread Aditya Mahajan via ntg-context
On Thu, 17 Nov 2022, Henning Hraban Ramm via ntg-context wrote: > Here’s an interesting example for annotated equations, done with LaTeX/TikZ: > https://mastodon.social/@sibin/109349703357749846 > > I guess something similar is possible with node anchors in ConTeXt/Me

Re: [NTG-context] annotated equations

2022-11-17 Thread Hans Hagen via ntg-context
On 11/17/2022 1:46 PM, Henning Hraban Ramm via ntg-context wrote: Here’s an interesting example for annotated equations, done with LaTeX/TikZ: https://mastodon.social/@sibin/109349703357749846 I guess something similar is possible with node anchors in ConTeXt/MetaPost? Mikael and I played

[NTG-context] annotated equations

2022-11-17 Thread Henning Hraban Ramm via ntg-context
Here’s an interesting example for annotated equations, done with LaTeX/TikZ: https://mastodon.social/@sibin/109349703357749846 I guess something similar is possible with node anchors in ConTeXt/MetaPost? Hraban

Re: [NTG-context] New VSCode extenstion using ConTeXt Language server

2022-11-09 Thread Ramkumar KB via ntg-context
; https://meeting.contextgarden.net/2022/talks/ramkumar/ramkumar-talk.pdf > > > > This supports ConTeXt markup and for any Lua code (within \startluacode & > \stopluacode) it re-directs to the Lua Language Server (from Sumneko - > https://github.com/sumneko/lua-language-server

Re: [NTG-context] New VSCode extenstion using ConTeXt Language server

2022-11-09 Thread Ramkumar KB via ntg-context
d for any Lua code (within > > \startluacode & \stopluacode) it re-directs to the Lua Language Server > > (from Sumneko - https://github.com/sumneko/lua-language-server > > <https://github.com/sumneko/lua-language-server> ) > > > > To Do - > >

Re: [NTG-context] New VSCode extenstion using ConTeXt Language server

2022-11-09 Thread Denis Maier via ntg-context
artluacode & \stopluacode) it re-directs to the Lua Language Server (from Sumneko - https://github.com/sumneko/lua-language-server ) To Do - 1. Make the source code open-source 2. Add new features (like Hover & Tooltip) 3. Work with Taco to add MetaPost Language Server (this co

Re: [NTG-context] New VSCode extenstion using ConTeXt Language server

2022-11-08 Thread Floris van Manen via ntg-context
er & Tooltip) 3. Work with Taco to add MetaPost Language Server (this could be challenging and interesting) Do give this a try and give your feedback. Note that this does not contain *all* the macros but covers the vast majority of the ConTeXt commands.

[NTG-context] New VSCode extenstion using ConTeXt Language server

2022-11-08 Thread Ramkumar KB via ntg-context
2. Add new features (like Hover & Tooltip) 3. Work with Taco to add MetaPost Language Server (this could be challenging and interesting) Do give this a try and give your feedback. Note that this does not contain *all* the macros but covers the vast majority of the ConTeXt commands.

Re: [NTG-context] Backgrounds has changed in latest lmtx

2022-10-21 Thread Otared Kavian via ntg-context
Hi Thomas, Your example does indeed show the issue I had reported on with Simpleslides: the backgrounds of the slides are not as expected. So it seems that beginning with version 2022-10-15 something has changed with Metapost or the background mechanism. Best regards: Otared > On 21 Oct 2

Re: [NTG-context] new upload

2022-10-17 Thread Hans Hagen via ntg-context
correctly with previous versions. Has Metapost changed some crucial settings ? some mp->tex interfacing macros were upgraded but that should not really matter much so i need an example of what goes wrong (quite some month ago we fixed some left/right page related interfacing but that should not aff

Re: [NTG-context] new upload

2022-10-17 Thread Otared Kavian via ntg-context
Metapost changed some crucial settings ? Best regards: Otared > On 16 Oct 2022, at 19:03, Mikael Sundqvist via ntg-context > wrote: > > Hi, > > On Sun, Oct 16, 2022 at 6:07 PM Aditya Mahajan via ntg-context > wrote: >> >> On Fri, 14 Oct 2022, Hans Hagen

Re: [NTG-context] (any) neovim users?

2022-10-14 Thread Nicola via ntg-context
t;> > when using % identification at the head of .tex source >> > files. >> >> The ConTeXt plugin (as well as MetaPost and MetaFont ones) has >> recently been rewritten in Vim 9 script (the new scripting language >> embedded in Vim), which NeoVim does not sup

Re: [NTG-context] (any) neovim users?

2022-10-14 Thread Alan Braslau via ntg-context
> > The ConTeXt plugin (as well as MetaPost and MetaFont ones) has > recently been rewritten in Vim 9 script (the new scripting language > embedded in Vim), which NeoVim does not support, afaik. See this > thread: https://github.com/vim/vim/issues/10968. > > One thing you can d

Re: [NTG-context] (any) neovim users?

2022-10-14 Thread Nicola via ntg-context
On 2022-10-14, Alan Braslau via ntg-context wrote: > A recent upgrade of the editor neovim leads to the following error > when using % identification at the head of .tex source files. The ConTeXt plugin (as well as MetaPost and MetaFont ones) has recently been rewritten in Vim 9 script (t

Re: [NTG-context] atan2 function

2022-10-14 Thread luigi scarso via ntg-context
ny math library. I really doubt that that code is faster than calling > atan2() > on a modern machine, but I’ve kept it in because using a lib might give > slightly > different results. > iirc, in metapost the whole scaled number system has n

Re: [NTG-context] atan2 function

2022-10-14 Thread Taco Hoekwater via ntg-context
tion. >> Here's an example with many lines and the angle function: >> https://pdfhost.io/v/1T4jgBnxh_scaled >> On Wed, Oct 12, 2022 at 11:42 PM Max Chernoff wrote: >>> >>> Hi, >>> >>>> How is atan2 called? I rolled my own as follows: >>&

Re: [NTG-context] atan2 function

2022-10-14 Thread Alan Braslau via ntg-context
Chernoff wrote: Hi, How is atan2 called? I rolled my own as follows: Is atan with two parameters supposed to behave like atan2? At mp-math.mpxl:167 there is: vardef atan primary x = angle(1,x) enddef ; The MetaPost manual says: The angle operator takes a pair

Re: [NTG-context] atan2 function

2022-10-13 Thread Thangalin via ntg-context
I rolled my own as follows: > > > Is atan with two parameters supposed to behave like atan2? > > At mp-math.mpxl:167 there is: > >vardef atan primary x = angle(1,x) enddef ; > > The MetaPost manual says: > >The angle operator takes a pair and comput

Re: [NTG-context] atan2 function

2022-10-13 Thread Max Chernoff via ntg-context
Hi, > How is atan2 called? I rolled my own as follows: > Is atan with two parameters supposed to behave like atan2? At mp-math.mpxl:167 there is: vardef atan primary x = angle(1,x) enddef ; The MetaPost manual says: The angle operator takes a pair and computes t

Re: [NTG-context] PDF viewer

2022-09-22 Thread Alan Braslau via ntg-context
s with complicated graphics (think MetaPost with hundreds of thousands of objects) get rendered pretty quickly, although one can see the very many objects being drawn the first time the page is displayed. Subsequently displays of these pages have no lag

[NTG-context] ConTeXt meeting and the annotated cow

2022-09-18 Thread Axel Kielhorn via ntg-context
Hello, last week I learned something about MetaPost at the context meeting. Thanks Taco! First a little background: I write a lot of documentation and sometimes I need to include a picture with annotations. Until now I used a drawing program to add text and arrows. This has one disadvantage

Re: [NTG-context] Latest ConTeXt won't "--make"

2022-09-14 Thread Max Chernoff via ntg-context
tightly integrates TeX and MetaPost in close cooperation with Lua. Updates will happen in sync with ConTeXt and when needed. Don't be fooled by unchanged dates: long term stability is the objective. $ context --version mtx-context | ConTeXt Process Management 1.04 mtx-context

Re: [NTG-context] update old MP code

2022-09-01 Thread Henning Hraban Ramm via ntg-context
never know which function is part of MetaPost/MetaFun, my editor’s syntax highlighting is incomplete... Hraban moireetest.tex Description: TeX document ___ If your question is of interest to others as well, please add

[NTG-context] update old MP code

2022-09-01 Thread Henning Hraban Ramm via ntg-context
Hi, here’s a snippet of old Metapost code that I’d like to use in ConTeXt. I didn’t manage to update it to MetaFun – can you help me? Hraban - \setupbodyfont[plex,ss,8bp] \startreusableMPgraphic{moiree} % 1994 by Bogusław Jackowski (GUST) defaultfont := "\truefontname{Sans}&quo

[NTG-context] MetaFun keywords extracted by mtxrun --script interface

2022-08-10 Thread Nicola via ntg-context
I am updating Vim syntax coloring for Metapost/MetaFun, which is now based on the files that are automatically generated with mtxrun --script interface --vim To test the results, I am opening ConTeXt's own MetaPost files in the editor and check how they look. It seems that the output

Re: [NTG-context] How to display these characters

2022-08-09 Thread Wolfgang Schuster via ntg-context
Henning Hraban Ramm via ntg-context schrieb am 09.08.2022 um 16:51: Am 08.08.22 um 08:01 schrieb Alan Braslau: On 05/08/22 05/08/22, 12:13, Henning Hraban Ramm via ntg-context wrote: I recently had the same problem and was wondering if there isn’t a Metapost module for directory trees

Re: [NTG-context] How to display these characters

2022-08-09 Thread Henning Hraban Ramm via ntg-context
Am 08.08.22 um 08:01 schrieb Alan Braslau: On 05/08/22 05/08/22, 12:13, Henning Hraban Ramm via ntg-context wrote: I recently had the same problem and was wondering if there isn’t a Metapost module for directory trees? There is a Metapost/Context module for drawing flow charts that should

Re: [NTG-context] How to display these characters

2022-08-08 Thread Alan Braslau via ntg-context
On 05/08/22 05/08/22, 12:13, Henning Hraban Ramm via ntg-context wrote: I recently had the same problem and was wondering if there isn’t a Metapost module for directory trees? There is a Metapost/Context module for drawing flow charts that should handle this nicely. There is also

Re: [NTG-context] How to display these characters

2022-08-05 Thread Henning Hraban Ramm via ntg-context
UI Symbols, Apple Symbols, Symbola, Droid Sans Fallback. I recently had the same problem and was wondering if there isn’t a Metapost module for directory trees? Hraban ___ If your question is of interest to othe

Re: [NTG-context] underbrace under matrix

2022-08-05 Thread Jethro Djan via ntg-context
Hi, I will wait for the manual. With drawing commutative diagrams, I am sure learning how to use MetaFun/MetaPost better might help. Thanks for the fantastic work. Jethro > On 5 Aug 2022, at 3:27 PM, Hans Hagen via ntg-context > wrote: > > On 8/5/2022 5:12 PM, Jethro Djan via

Re: [NTG-context] m-graph label

2022-07-30 Thread John Kitzmiller via ntg-context
s are given as comments in mp-grap.mpiv that you can follow. > Also attached is an adapted version of the original John Hobby > documentation, with extensions described. > > Note that the m-graph module is simply a re-write of the John Hobby > graph macros,

Re: [NTG-context] m-graph label

2022-07-26 Thread Alan via ntg-context
iginal John Hobby documentation, with extensions described. Note that the m-graph module is simply a re-write of the John Hobby graph macros, taking advantage of floating-point MetaPost (thus simplified). I have been working on a completely new luagraph module that doe

Re: [NTG-context] Set up external figure for particular image type

2022-07-18 Thread Wolfgang Schuster via ntg-context
Thangalin via ntg-context schrieb am 18.07.2022 um 19:10: Thank you, Wolfgang. That looks promising. SVG files are converted using MetaPost. I thought the following would work: svg=>{\externalfigure[#1][svg][conversion=mp]} You can probably remove the second argument ([svg]) wh

Re: [NTG-context] Set up external figure for particular image type

2022-07-18 Thread Thangalin via ntg-context
Thank you, Wolfgang. That looks promising. SVG files are converted using MetaPost. I thought the following would work: svg=>{\externalfigure[#1][svg][conversion=mp]} Is there anything else that needs to happen to ensure SVG files are piped through MetaPost? Thanks ag

Re: [NTG-context] MetaPost cutdraw

2022-07-06 Thread Mikael Sundqvist via ntg-context
>> > >>> Hi, I’m trying to understand MetaPost better. > >>> > >>> I’d like to draw a fat line that’s cut at its end points. > >> > >> You mean like linecap = butt? > > Yes, but that doesn’t behave differently. > > > &g

Re: [NTG-context] MetaPost label font size

2022-07-06 Thread Henning Hraban Ramm via ntg-context
Am 06.07.22 um 15:24 schrieb Fabrice L: Here are slightly different syntax that could be useful perhaps ? In the second one, the scaled parameter can be replaced easily with a variable, so you can decide and change the size of the label during the course of a picture. Thank you (all), I

Re: [NTG-context] MetaPost label font size

2022-07-06 Thread Fabrice L via ntg-context
> Le 5 juill. 2022 à 19:00, Henning Hraban Ramm via ntg-context > a écrit : > > How can I change the font size of labels within one picture? > > Hraban > > \startMPpage > defaultfont := "\truefontname{Sans}"; > defaultfontsize := \the\bodyfontsize; > > label.top(defaultfontsize, (0,0)); >

Re: [NTG-context] MetaPost label font size

2022-07-06 Thread Hans Hagen via ntg-context
On 7/6/2022 1:36 PM, Henning Hraban Ramm via ntg-context wrote: Am 06.07.22 um 12:45 schrieb Hans Hagen via ntg-context: On 7/6/2022 12:19 PM, fv leung via ntg-context wrote: My stupid way to get labels of different sizes: \starttext \startMPcode    label("normal label", (0, 0));   

Re: [NTG-context] MetaPost label font size

2022-07-06 Thread fv leung via ntg-context
I've used something like the following before. \starttext \startMPcode label("normal label", (0, 0)); label("{\switchtobodyfont[3pt] tiny label}", (0, 18)); label("{\switchtobodyfont[72pt] giant label}", (0, -72)); \stopMPcode \stoptext Henning Hraban Ramm via ntg-context 於

Re: [NTG-context] MetaPost label font size

2022-07-06 Thread Henning Hraban Ramm via ntg-context
Am 06.07.22 um 12:45 schrieb Hans Hagen via ntg-context: On 7/6/2022 12:19 PM, fv leung via ntg-context wrote: My stupid way to get labels of different sizes: \starttext \startMPcode    label("normal label", (0, 0));    label("\setsmallbodyfont small label", (0, 18));   

Re: [NTG-context] MetaPost label font size

2022-07-06 Thread Hans Hagen via ntg-context
On 7/6/2022 12:19 PM, fv leung via ntg-context wrote: My stupid way to get labels of different sizes: \starttext \startMPcode   label("normal label", (0, 0));   label("\setsmallbodyfont small label", (0, 18));   label("\setbigbodyfont big label", (0, -18)); \stopMPcode \stoptext

Re: [NTG-context] MetaPost label font size

2022-07-06 Thread fv leung via ntg-context
My stupid way to get labels of different sizes: \starttext \startMPcode label("normal label", (0, 0)); label("\setsmallbodyfont small label", (0, 18)); label("\setbigbodyfont big label", (0, -18)); \stopMPcode \stoptext Henning Hraban Ramm via ntg-context 於 2022年7月6日 週三 下午5:23寫道: >

Re: [NTG-context] MetaPost cutdraw

2022-07-06 Thread Henning Hraban Ramm via ntg-context
Am 06.07.22 um 09:15 schrieb Hans Hagen via ntg-context: On 7/6/2022 7:10 AM, Aditya Mahajan via ntg-context wrote: On Wed, 6 Jul 2022, Henning Hraban Ramm via ntg-context wrote: Hi, I’m trying to understand MetaPost better. I’d like to draw a fat line that’s cut at its end points. You

Re: [NTG-context] MetaPost label font size

2022-07-06 Thread Henning Hraban Ramm via ntg-context
Am 06.07.22 um 07:17 schrieb Aditya Mahajan via ntg-context: On Wed, 6 Jul 2022, Henning Hraban Ramm via ntg-context wrote: How can I change the font size of labels within one picture? (Untested): See https://www.contextgarden.net/Command/setupMPinstance

Re: [NTG-context] MetaPost cutdraw

2022-07-06 Thread Hans Hagen via ntg-context
On 7/6/2022 7:10 AM, Aditya Mahajan via ntg-context wrote: On Wed, 6 Jul 2022, Henning Hraban Ramm via ntg-context wrote: Hi, I’m trying to understand MetaPost better. I’d like to draw a fat line that’s cut at its end points. You mean like linecap = butt? \startMPpage[offset=5mm] path p

Re: [NTG-context] MetaPost label font size

2022-07-05 Thread Aditya Mahajan via ntg-context
On Wed, 6 Jul 2022, Henning Hraban Ramm via ntg-context wrote: > How can I change the font size of labels within one picture? (Untested): See https://www.contextgarden.net/Command/setupMPinstance \setupMPinstance[metafun][textstyle=sans] Or define a new instance, which sets the textstyle to

Re: [NTG-context] MetaPost cutdraw

2022-07-05 Thread Aditya Mahajan via ntg-context
On Wed, 6 Jul 2022, Henning Hraban Ramm via ntg-context wrote: > Hi, I’m trying to understand MetaPost better. > > I’d like to draw a fat line that’s cut at its end points. You mean like linecap = butt? \startMPpage[offset=5mm] path p; p := origin -- (7cm,0); interim lineca

[NTG-context] MetaPost label font size

2022-07-05 Thread Henning Hraban Ramm via ntg-context
How can I change the font size of labels within one picture? Hraban \startMPpage defaultfont := "\truefontname{Sans}"; defaultfontsize := \the\bodyfontsize; label.top(defaultfontsize, (0,0)); defaultfontsize := 4bp; label.top(defaultfontsize, (50,0)); % shows that the variable changed, % but

[NTG-context] MetaPost cutdraw

2022-07-05 Thread Henning Hraban Ramm via ntg-context
Hi, I’m trying to understand MetaPost better. I’d like to draw a fat line that’s cut at its end points. I learned, “cutdraw” should do the trick, but I get a parallelogram instead of a rectangle. What’s wrong? Hraban \startMPpage draw (0,20)--(20,20) withpen pensquare scaled 10; cutdraw

Re: [NTG-context] SVG text alignment issue

2022-06-29 Thread Thangalin via ntg-context
; On 6/29/2022 8:48 PM, Thangalin wrote: > > > To me, it looks like the text, after a rotational transform, is being > > written to the baseline rather than (cap height + descender height) / 2, > > which seems to be a MetaPost conversion issue? There's another, possibly > &g

Re: [NTG-context] SVG text alignment issue

2022-06-29 Thread Hans Hagen via ntg-context
On 6/29/2022 8:48 PM, Thangalin wrote: To me, it looks like the text, after a rotational transform, is being written to the baseline rather than (cap height + descender height) / 2, which seems to be a MetaPost conversion issue? There's another, possibly related issue, which I'll provide

Re: [NTG-context] SVG text alignment issue

2022-06-29 Thread Thangalin via ntg-context
Note how the text is vertically centered above the vertical line. To me, it looks like the text, after a rotational transform, is being written to the baseline rather than (cap height + descender height) / 2, which seems to be a MetaPost conversion issue? There's another, possibly related issue

Re: [NTG-context] How do I turn off indentation inside a \framed with align=?

2022-06-03 Thread Wolfgang Schuster via ntg-context
rovide a minimal example (how much I would like to) as my TeX is produced in a pipeline from 5600 lines of lua and METAPOST code. But luckily, in this case I can, the one using \phrasetext is indented, the other one is not.: \setuplanguage[en][patterns={en}]\mainlanguage[en] \definelabe

Re: [NTG-context] How do I turn off indentation inside a \framed with align=?

2022-06-02 Thread Gerben Wierda via ntg-context
d in a pipeline from 5600 lines of lua and METAPOST code. But luckily, in this case I can, the one using \phrasetext is indented, the other one is not.: \setuplanguage[en][patterns={en}]\mainlanguage[en] \definelabelclass[phrase] \setupphrasetext[en][metamodelexplanation= {Only direct rela

Re: [NTG-context] Compiling a large metapost document

2022-06-02 Thread Stefan Nedeljkovic via ntg-context
Thanks for the advice, Hans. I'll try that! On Thu, Jun 2, 2022 at 12:17 PM Hans Hagen via ntg-context < ntg-context@ntg.nl> wrote: > On 6/1/2022 8:34 PM, Thomas A. Schmitz via ntg-context wrote: > > > > > > On 6/1/22 19:35, Stefan Nedeljkovic via ntg-context wrote: > >> Sorry, i just updated

Re: [NTG-context] Compiling a large metapost document

2022-06-02 Thread Hans Hagen via ntg-context
On 6/1/2022 8:34 PM, Thomas A. Schmitz via ntg-context wrote: On 6/1/22 19:35, Stefan Nedeljkovic via ntg-context wrote: Sorry, i just updated the file, should now compile, but fail due to resources. Are the configuration options to context that would enable this file to be compiled? The

Re: [NTG-context] Compiling a large metapost document

2022-06-02 Thread Stefan Nedeljkovic via ntg-context
I just bumped it to double the size, did mtxrun --reload, context --generate and the error is still tex memory > bumping category 'token' failed, details: all=8000 | ini=4 We ran into troubles scanning an argument. On Thu, Jun 2, 2022 at 9:20 AM Thomas A. Schmitz via ntg-context <

Re: [NTG-context] Compiling a large metapost document

2022-06-02 Thread Thomas A. Schmitz via ntg-context
On 01.06.22 23:30, Stefan Nedeljkovic wrote: I Tried editing the file context/tex/texmf/web2c/texmfcnf.lua, and running context --generate, context --make, but the error persists. I'm new to context and I don't know how to configure this file. Running --usage reveals in the log that the

Re: [NTG-context] Compiling a large metapost document

2022-06-01 Thread Stefan Nedeljkovic via ntg-context
I figured it out. I was wrongly calculating the page size argument for gs. Thank you very, very much again Max! On Thu, Jun 2, 2022 at 4:41 AM Stefan Nedeljkovic wrote: > There is one more problem: the pdf generated has incorrect margins. I > tried to manually calculate the size in ps points

Re: [NTG-context] Compiling a large metapost document

2022-06-01 Thread Stefan Nedeljkovic via ntg-context
There is one more problem: the pdf generated has incorrect margins. I tried to manually calculate the size in ps points and run gs directly, but the results are the same. How can I get an accurate rendering of the page? On Thu, Jun 2, 2022 at 4:22 AM Max Chernoff wrote: > On 2022-06-01 8:00

Re: [NTG-context] Compiling a large metapost document

2022-06-01 Thread Max Chernoff via ntg-context
On 2022-06-01 8:00 p.m., Stefan Nedeljkovic wrote: Thank you very much Max! It works indeed! One more question. How would I import the eps file back into MPpage, so I could do trickery with text. Convert the PostScript file into PDF with either "ps2pdf" or GhostScript, then you can import the

Re: [NTG-context] Compiling a large metapost document

2022-06-01 Thread Stefan Nedeljkovic via ntg-context
Thank you very much Max! It works indeed! One more question. How would I import the eps file back into MPpage, so I could do trickery with text. ) On Thu, Jun 2, 2022 at 1:46 AM Max Chernoff wrote: > > I have a large .tex file with metapost embedded in it and want to c

Re: [NTG-context] Compiling a large metapost document

2022-06-01 Thread Max Chernoff via ntg-context
I have a large .tex file with metapost embedded in it and want to compile it, but it fails. Do you know of a way to compile it? Just use plain MetaPost: diff --git a/belgrade_gm.tex b/belgrade_gm.mp index 3281754..d536b64 100644 --- a/belgrade_gm.tex +++ b/belgrade_gm.mp

Re: [NTG-context] Compiling a large metapost document

2022-06-01 Thread Bruce Horrocks via ntg-context
> On 1 Jun 2022, at 22:30, Stefan Nedeljkovic via ntg-context > wrote: > > Dear Thomas, > > I'm sorry for all the shortcomings of my question. I'll try to be more > concrete. If you won't download my file, could you at least give me a hint on > how to configure LMTX? > > I Tried editing

Re: [NTG-context] Compiling a large metapost document

2022-06-01 Thread Stefan Nedeljkovic via ntg-context
Dear Thomas, I'm sorry for all the shortcomings of my question. I'll try to be more concrete. If you won't download my file, could you at least give me a hint on how to configure LMTX? I Tried editing the file context/tex/texmf/web2c/texmfcnf.lua, and running context --generate, context --make,

Re: [NTG-context] Compiling a large metapost document

2022-06-01 Thread Thomas A. Schmitz via ntg-context
On 6/1/22 22:15, Stefan Nedeljkovic via ntg-context wrote: The problem *is* the file size. There is not a minimal example, because everything works when there is less drawdot commands. There is 125000+ drawdot commands in the file. The run ends with the message: If you really absolutely need

Re: [NTG-context] Compiling a large metapost document

2022-06-01 Thread Stefan Nedeljkovic via ntg-context
P.S. Use the last link I posted, the updated file is there. On Wed, Jun 1, 2022 at 10:15 PM Stefan Nedeljkovic wrote: > The problem *is* the file size. There is not a minimal example, > because everything works when there is less drawdot commands. There is > 125000+ drawdot commands in the

Re: [NTG-context] Compiling a large metapost document

2022-06-01 Thread Stefan Nedeljkovic via ntg-context
The problem *is* the file size. There is not a minimal example, because everything works when there is less drawdot commands. There is 125000+ drawdot commands in the file. The run ends with the message: If you really absolutely need more capacity, you can ask a wizard to enlarge me. mtx-context

Re: [NTG-context] Compiling a large metapost document

2022-06-01 Thread Thomas A. Schmitz via ntg-context
On 6/1/22 19:35, Stefan Nedeljkovic via ntg-context wrote: Sorry, i just updated the file, should now compile, but fail due to resources. Are the configuration options to context that would enable this file to be compiled? The question still stands: what do you expect us to do? Hunt for a

Re: [NTG-context] Compiling a large metapost document

2022-06-01 Thread Stefan Nedeljkovic via ntg-context
ext < > ntg-context@ntg.nl> wrote: > > > > Just fixed the file, here is the new link: > https://drive.google.com/file/d/16jTzHbaqxPmhgmNaDOBRijlhlmUCnH4j/view?usp=sharing > > > > On Wed, Jun 1, 2022 at 4:48 PM Stefan Nedeljkovic > wrote: > > Dear list, >

Re: [NTG-context] Compiling a large metapost document

2022-06-01 Thread Bruce Horrocks via ntg-context
fan Nedeljkovic via ntg-context > wrote: > > Just fixed the file, here is the new link: > https://drive.google.com/file/d/16jTzHbaqxPmhgmNaDOBRijlhlmUCnH4j/view?usp=sharing > > On Wed, Jun 1, 2022 at 4:48 PM Stefan Nedeljkovic wrote: > Dear list, > > I have a large .t

Re: [NTG-context] Compiling a large metapost document

2022-06-01 Thread Stefan Nedeljkovic via ntg-context
Just fixed the file, here is the new link: https://drive.google.com/file/d/16jTzHbaqxPmhgmNaDOBRijlhlmUCnH4j/view?usp=sharing On Wed, Jun 1, 2022 at 4:48 PM Stefan Nedeljkovic wrote: > Dear list, > > I have a large .tex file with metapost embedded in it and want to compile > it,

[NTG-context] Compiling a large metapost document

2022-06-01 Thread Stefan Nedeljkovic via ntg-context
Dear list, I have a large .tex file with metapost embedded in it and want to compile it, but it fails. Here is a link to the file (~12MB): https://drive.google.com/file/d/1t-6mxFmGp-nzpl0RrPgNFq8KRvpplgDv/view?usp=sharing Do you know of a way to compile it? BTW, the file is automatically

[NTG-context] no update

2022-05-27 Thread Hans Hagen via ntg-context
Hi, no weekend update ... Mikael and I are working on / upgrading some math stuff (numbering) and don't want it to be too bad, as well as (new / improved) metapost stuff that we need to test first (and that also involves quite some experiments and documentation) Hans

Re: [NTG-context] How to add margin around standalone MetaPost?

2022-05-24 Thread Vincent Hennebert via ntg-context
On Sat, 2022-05-21 at 07:39 +0530, śrīrāma wrote: > On 5/20/22 10:26 PM Vincent Hennebert via ntg-context wrote: > > Take the following MetaPost file: > > > > beginfig(0) > >   ahlength := 20; > >   linejoin := mitered; > >   drawarrow origin--(40,0)

Re: [NTG-context] Metapost examples seems broken

2022-05-22 Thread Bruce Horrocks via ntg-context
It's archived here <https://web.archive.org/web/20210815171931/https://tex.loria.fr/prod-graph/zoonekynd/metapost/metapost.html> which might suffice until the author gets his certificates sorted out? > On 22 May 2022, at 09:41, Jan-Erik Hägglöf via ntg-context > wrote: > &g

Re: [NTG-context] Interactive checkbox in ConTeXt

2022-05-22 Thread Jan-Erik Hägglöf via ntg-context
Thank you for the useful tip. > > I’ve tested the example given below but ran into missing figure, maybe I need > to reconstruct the MetaPost file as mentioned in setup. Se attached example: > > Thanks in advance! > > /Jan-Erik > > \setupinteraction[state=start] >

Re: [NTG-context] Interactive checkbox in ConTeXt

2022-05-22 Thread Jan-Erik Hägglöf via ntg-context
Thank you for the useful tip. I’ve tested the example given below but ran into missing figure, maybe I need to reconstruct the MetaPost file as mentioned in setup. Se attached example: Thanks in advance! /Jan-Erik \setupinteraction[state=start] \setupexternalfigures[location=global

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