Drawing vector graphics using a command line

John D Lamb J.D.Lamb at johndlamb.net
Sun Sep 20 19:52:17 UTC 2015

On 20/09/15 13:44, Johnny Rosenberg wrote:
> Anyone know of a tool to create SVG files (or similar) using some kind
> of macro or command line?

Two suggestions.

First, if you can tolerate encapsulated postscript, you can use LaTeX. 
The following is an example I used recently:


%% Pictures



This draws a pentagon with dashed and solid lines and nodes at the 
vertices. To convert to pdf use estopdf.

I used to write raw PostScript. But I rarely do this now that the LaTeX 
  PSTricks packages do what I want for simple graphics and R can handle 
the really complex stuff.

Second, IIRC SVG is a language you can just write. Have a look at some 
of these examples: http://www.w3schools.com/svg/svg_examples.asp. I have 
written some SVGs several years back, but usually I need pdf or eps 
format nowadays.

John D Lamb

More information about the ubuntu-users mailing list