dumpToSVG

dumpToSVG — add an export capability into SVG files.

Synopsis

#include <extensions/box.h>
#include <extensions/axes.h>
#include <visu_pairs.h and visu_data.h>

void                (*VisuDumpCairoAdd)                 (cairo_t *cr,
                                                         guint width,
                                                         guint height);
const VisuDump *    visu_dump_cairo_pdf_getStatic       ();
void                visu_dump_cairo_setPostFunc         (VisuDumpCairoAdd func);
const VisuDump *    visu_dump_cairo_svg_getStatic       ();

Description

This provides a write routine to export V_Sim views into SVG files. Currently, this is an experimental feature. Not all V_Sim elements are rendered, only the nodes, the box, the pairs and the axes. All the characteristics are not used (no line stipple for instance). In spin mode, nodes are only atomic.

Details

VisuDumpCairoAdd ()

void                (*VisuDumpCairoAdd)                 (cairo_t *cr,
                                                         guint width,
                                                         guint height);

A method to be called by V_Sim after exportation to allow post-processing.

cr :

a cairo_t context.

width :

width of the surface.

height :

height of the surface.

visu_dump_cairo_pdf_getStatic ()

const VisuDump *    visu_dump_cairo_pdf_getStatic       ();

This routine returns the dump object to PDF format.

Returns :

a newly created dump object to create SVG files. [transfer none]

visu_dump_cairo_setPostFunc ()

void                visu_dump_cairo_setPostFunc         (VisuDumpCairoAdd func);

Allow to add a function that will be called on every Cairo exportation after V_Sim rendering to allow post-processing.

func :

a VisuDumpCairoAdd function or NULL. [allow-none][scope call]

Since 3.7


visu_dump_cairo_svg_getStatic ()

const VisuDump *    visu_dump_cairo_svg_getStatic       ();

This routine returns the dump object to SVG format.

Returns :

a newly created dump object to create SVG files. [transfer none]