Thread: generate svg

  1. #1
    Registered User
    Join Date
    Mar 2008
    Posts
    82

    generate svg

    in seeking to embellish some text and lines output I have,
    I though about using SVG.

    On a quick glance, there are a number of libraries out that seemed to have proved their stability over the years, cairo, pango, librsvg, but they are part of farily big projects and of course you surrender a little to portability if you decide to depend on them.

    Of course, it's possible to just generate the XML-SVG text within the C prog itself, but on that count you doing a little wheel inventing.

    Has anybody given this a think? Any comments? Thanks in adv!

  2. #2
    Make Fortran great again
    Join Date
    Sep 2009
    Posts
    1,413
    Personally, I like cairo because it's mature, cross-platform and has a variety of different output targets (PDF, SVG, Postscript, etc). That and the API is very simple: Cairo Tutorial. It has very nice results.

    P.S. Pango is for text, cairo can do both text and graphics.

  3. #3
    Registered User
    Join Date
    Mar 2008
    Posts
    82
    Hi Epy,

    Yes, I was having a closer look at it ... I use linux and have to share code with people using Mac OS X, don't know if I ask them to make sure they have cairo installed befoe they run my prog.

    Thanks for answer.

  4. #4
    Make Fortran great again
    Join Date
    Sep 2009
    Posts
    1,413
    Download

    Look down near the bottom under 'Mac OS X', seems like it might be a matter of a simple sudo statement.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Template metaprogramming, whats the point?
    By Cogman in forum C++ Programming
    Replies: 26
    Last Post: 02-01-2009, 11:47 PM
  2. Replies: 2
    Last Post: 03-13-2008, 05:45 AM
  3. Generate random numbers in Lucky7 project using C#
    By Grayson_Peddie in forum C# Programming
    Replies: 1
    Last Post: 04-11-2003, 11:03 PM
  4. Replies: 11
    Last Post: 07-16-2002, 11:39 AM
  5. Best way to generate a random double?
    By The V. in forum C Programming
    Replies: 3
    Last Post: 10-16-2001, 04:11 PM