How to view output .mp files from Functional MetaPost

Posted by Jared Updike on Stack Overflow See other posts from Stack Overflow or by Jared Updike
Published on 2008-10-23T07:11:47Z Indexed on 2010/05/10 13:24 UTC
Read the original article Hit count: 522

Filed under:
|
|
|

I'm interested in using Functional MetaPost on Mac OS X:

http://cryp.to/funcmp/

I'm looking for a tutorial like:

http://haskell.org/haskellwiki/Haskell_in_5_steps

but for a trivial FuncMP example, i.e. using GHC, I can compile something simple such as:

import FMP  
myPicture = text "blah"  
main = generate "foo" 1 myPicture

but I can't figure out how to view this foo.1.mp output. (It gives a runtime error about not finding 'virmp'; my MetaPost binary is 'mpost'; I can't figure out how to override this Parameter or what my .FunMP file is or should be doing...) I can run mpost on that but the output (foo.1.1) is what, PostScript? EPS? How do I use this? (I imagine I just need a simple LaTeX file with an EPS figure in it or something...)

Preferably, I'd like to generate output (.ps or .pdf that I can view) so I an actually get somewhere with Functional MetaPost, learning it, playing with it, not banging my head against paths and binaries and shell commands.

© Stack Overflow or respective owner

Related posts about haskell

Related posts about latex