Changes

Jump to navigation Jump to search
2,331 bytes added ,  17:28, 8 June 2020
m
no edit summary
< Some lucky people will be able to produce all their documents in [[GraphicsMetaPost]]and ConTeXt and never have to worry about the ugly world of MS Word, PowerPoint and Visio. Unfortunately, most of us will, at some point, have to share our graphics with colleagues who are unenlightened.
= Sharing This page includes methods of sharing graphics =/figures with co-workers who do not use ConTeXt.This includes importing to and exporting from ConTeXt.
 = Exporting MetaPost drawings as PDF files =PDF can be generated from MetaPost code using [http://www.pragma-ade.com/general/sources/mptopdf.pdf MPtoPDF] or <code>texexec --mptex</code>. But where a drawing uses ConTeXt to generate formatted text or labels, it is necessary to generate a document which contains the graphic. This can be achieved, with the page includes methods cropped to the size of the graphic, using the following construct: <texcode>\starttext \startMPpage draw fullcircle scaled 10cm ; \stopMPPage\stoptext</texcode> See also {{cmd|startMPpage}}. = Importing MetaPost drawings into MS Word or PowerPoint =MS Word can import pictures in many graphics formats, but not PDF. Two of sharing the available options are:* Use encapsulated postscript (EPS). This provides graphics which print perfectly (on a PS printer) but which look blocky on screen, so are unsuitable for PowerPoint presentations.* Use scalable vector graphics(SVG) as an intermediate format between PDF and the MS Visio tool. == Converting to EPS ==MetaPost drawings can be converted to encapsulated postscript as follows:* Create a PDF drawing (see "Exporting MetaPost drawing as PDF files" above).* From the command line, convert to EPS using pdftops:<code>pdftops -eps -pagecrop myfile.pdf</figures code>* Import the EPS file as a picture into Word.Note that the preview on-screen in Word is of poor quality, but when printed it should have the full quality of the original. ==Converting to Visio via SVG ==Visio is another Microsoft product whose .VSD files can be imported directly into Word or PowerPoint, giving good reproduction on screen and (usually) in print. Luckily, Visio will import SVG files. The steps to achieve this are:* Create a SVG file directly by running metapost 1.2 with co<tt>-workers who soutputformat="svg"</tt> or* Create an SVG file by conversion via** MP to PDF (probablysee above) do not use ConTeXt.This includes importing ** [http://www.tlhiv.org/MetaPost/tools/mptosvg MPtoSVG] to convert to and exporting SVG.* Load SVG into Visio.* Save as VSD file from ConTeXtVisio.* Import VSD into Word or PowerPoint.Phew!
[[Category:Graphics]]
[[Category:Metapost]]
[[Category:Sciences]]

Navigation menu