Drawing vector graphics using a command line

Douglas Pollard dougpol2 at gmail.com
Mon Sep 21 15:55:56 UTC 2015


This is maybe off topic, But Linux CNC wil draw on screen almost 
anything you can think of and it comes in ubuntu.  I believe it can be 
run in camand line as well. I designed a couple boats and built them to 
sell.   Works great for some things.  Doug

On 09/21/2015 09:51 AM, Liam Proven wrote:
> On 20 September 2015 at 21:52, John D Lamb <J.D.Lamb at johndlamb.net> wrote:
>> 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:
>>
>> \documentclass{article}
>> \usepackage{mathptmx}
>>
>> %% Pictures
>> \usepackage{pst-pdf,pst-node}
>>
>> \begin{document}
>> \begin{pspicture}[showgrid=false](0,0)(2,2)
>>    \psset{arrows=->}
>>    \rput(0.529,0.353){\dotnode{V1}}
>>    \rput(1.470,0.353){\dotnode{V2}}
>>    \rput(1.712,1.247){\dotnode{V3}}
>>    \rput(1.000,1.800){\dotnode{V4}}
>>    \rput(0.239,1.247){\dotnode{V5}}
>>
>>    \ncline[linestyle=dashed]{V1}{V2}
>>    \ncline{V3}{V2}
>>    \ncline{V4}{V3}
>>    \ncline{V5}{V4}
>>    \ncline{V1}{V5}
>> \end{pspicture}
>> \end{document}
>>
>> 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.
>
> The trusty standby xterm, preloaded onto almost all Linux distros,
> supports Tektronix graphics terminal drawing commands...
>
> http://stackoverflow.com/questions/2114347/raster-graphics-in-xterm
>
>





More information about the ubuntu-users mailing list