Re: [NTG-context] Saving Metafun Graphic for use outside ConTeXt

2018-04-05 Thread Keith McKay

Thanks dr. Hans! It certainly will.

Best Wishes

Keith


On 05/04/2018 19:55, dr. Hans van der Meer wrote:

Maybe this script could help a bit too.


Use with following code scheme in ConTeXt:

\starttex
t\startMPpage
% Your Metapost/metafun code here
\stopMPpage
\stoptext

It will produce a standalone image in a pdf.


dr. Hans van der Meer


On 5 Apr 2018, at 18:45, Keith McKay > wrote:


Thanks Nicola and Alan. I'll look into that.

Best Wishes

Keith


On 05/04/2018 17:42, Nicola wrote:

On 05/04/2018 18:24, Alan Braslau wrote:

On Thu, 5 Apr 2018 15:28:34 +0100
Keith McKay  wrote:


I use a mac-mini and it seems that mupdf, of which mutools is part
off, does not have a macOS version, or I would have to build from
source. However it looks like I can use Inkscape with a wee bit
thought to do pretty much the same.


mupdf is available on MacPorts...


...also in Homebrew (mupdf formula, or mupdf-tools if you don't need
the viewer).

Nicola

___ 

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/listinfo/ntg-context

webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___



___
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/listinfo/ntg-context

webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___




___
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/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___



___
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/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] Saving Metafun Graphic for use outside ConTeXt

2018-04-05 Thread dr. Hans van der Meer
Maybe this script could help a bit too. 

mpone
Description: Binary data
Use with following code scheme in ConTeXt:\starttext\startMPpage% Your Metapost/metafun code here\stopMPpage\stoptextIt will produce a standalone image in a pdf.
dr. Hans van der Meer

On 5 Apr 2018, at 18:45, Keith McKay  wrote:
  


  
  Thanks Nicola and Alan. I'll look into that.Best WishesKeith


On 05/04/2018 17:42, Nicola wrote:

On 05/04/2018
  18:24, Alan Braslau wrote:
  
  On Thu, 5
Apr 2018 15:28:34 +0100

Keith McKay  wrote:


I use a
  mac-mini and it seems that mupdf, of which mutools is part
  
  off, does not have a macOS version, or I would have to build
  from
  
  source. However it looks like I can use Inkscape with a wee
  bit
  
  thought to do pretty much the same.
  


mupdf is available on MacPorts...

  
  
  ...also in Homebrew (mupdf formula, or mupdf-tools if you don't
  need
  
  the viewer).
  
  
  Nicola
  
  
___
  
  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/listinfo/ntg-context
  
  webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
  
  archive  : https://bitbucket.org/phg/context-mirror/commits/
  
  wiki : http://contextgarden.net
  
___



  

___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/listinfo/ntg-contextwebpage  : http://www.pragma-ade.nl / http://context.aanhet.netarchive  : https://bitbucket.org/phg/context-mirror/commits/wiki : http://contextgarden.net__
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/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] Saving Metafun Graphic for use outside ConTeXt

2018-04-05 Thread Keith McKay

Thanks Nicola and Alan. I'll look into that.

Best Wishes

Keith


On 05/04/2018 17:42, Nicola wrote:

On 05/04/2018 18:24, Alan Braslau wrote:

On Thu, 5 Apr 2018 15:28:34 +0100
Keith McKay  wrote:


I use a mac-mini and it seems that mupdf, of which mutools is part
off, does not have a macOS version, or I would have to build from
source. However it looks like I can use Inkscape with a wee bit
thought to do pretty much the same.


mupdf is available on MacPorts...


...also in Homebrew (mupdf formula, or mupdf-tools if you don't need
the viewer).

Nicola

___ 

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/listinfo/ntg-context

webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___



___
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/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] Saving Metafun Graphic for use outside ConTeXt

2018-04-05 Thread Nicola

On 05/04/2018 18:24, Alan Braslau wrote:

On Thu, 5 Apr 2018 15:28:34 +0100
Keith McKay  wrote:


I use a mac-mini and it seems that mupdf, of which mutools is part
off, does not have a macOS version, or I would have to build from
source. However it looks like I can use Inkscape with a wee bit
thought to do pretty much the same.


mupdf is available on MacPorts...


...also in Homebrew (mupdf formula, or mupdf-tools if you don't need
the viewer).

Nicola

___
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/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] Saving Metafun Graphic for use outside ConTeXt

2018-04-05 Thread Alan Braslau
On Thu, 5 Apr 2018 15:28:34 +0100
Keith McKay  wrote:

> I use a mac-mini and it seems that mupdf, of which mutools is part
> off, does not have a macOS version, or I would have to build from
> source. However it looks like I can use Inkscape with a wee bit
> thought to do pretty much the same.

mupdf is available on MacPorts...

Alan
___
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/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] Saving Metafun Graphic for use outside ConTeXt

2018-04-05 Thread Keith McKay

Thanks Hans for the advice.

I use a mac-mini and it seems that mupdf, of which mutools is part off, 
does not have a macOS version, or I would have to build from source. 
However it looks like I can use Inkscape with a wee bit thought to do 
pretty much the same.


Thanks again for your help.

Keith


On 05/04/2018 13:39, Hans Hagen wrote:

On 4/5/2018 1:10 PM, Keith McKay wrote:

Dear Readers,

I have been playing about with METAFUN over the last few days trying 
to get a feel for it. I was wondering if it is possible to save the 
graphics produced in a context document for use outside. On looking 
at the Metapost manual I see you can using the following commands 
save a graphic as an svg file.


forget about producing svg this way ... (1) it would not work with 
fonts, and (2) mplib in luatex has svg and png output disabled.


% file: mpsvg.tex

\startMPpage

    draw textext("Does it work?") ;

    draw boundingbox currentpicture enlarged 2mm withcolor "darkred" ;

\stopMPpage

% process

context mpsvg

mutool convert -o mpsvg.svg mpsvg.pdf

Hans

-
  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/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] Saving Metafun Graphic for use outside ConTeXt

2018-04-05 Thread Hans Hagen

On 4/5/2018 1:10 PM, Keith McKay wrote:

Dear Readers,

I have been playing about with METAFUN over the last few days trying to 
get a feel for it. I was wondering if it is possible to save the 
graphics produced in a context document for use outside. On looking at 
the Metapost manual I see you can using the following commands save a 
graphic as an svg file.


forget about producing svg this way ... (1) it would not work with 
fonts, and (2) mplib in luatex has svg and png output disabled.


% file: mpsvg.tex

\startMPpage

draw textext("Does it work?") ;

draw boundingbox currentpicture enlarged 2mm withcolor "darkred" ;

\stopMPpage

% process

context mpsvg

mutool convert -o mpsvg.svg mpsvg.pdf

Hans

-
  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/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___