fig2vect Documentation

1.1.23

The main() function checks, whether to run silently, craetes an application structure and invokes run_the_program().The run_the_program() function processes the command line arguments, creates a conversion job structure and invokes dkfig_co_run() or one of the functions to handle application options (-h, -v, -c, -u, -C).

The dkfig_co_run() function searches for the base driver name, loads the configuration file, processes the command line options and invokes lets_go_now().

The lets_go_now() function inspects input and output file name.

The run_for_filenames(), run_with_ifn2(), run_for_stdio(), run_with_istream() and run_with_ofn2() functions expand wildcards in file names if necessary and open streams for input and output. Finally these functions call run_for_streams().

The run_for_streams() function creates a new Fig drawing structure and transfers setup options needed while reading a Fig file from the conversion job structure into the Fig drawing structure. The dkfig_co_add_stream() function is used to read the Fig file, the dkfig_co_out_to_stream() function produces the output file. This function calls one the driver functions.

Most of the driver functions use 2 passes: One pass to gather information about all object styles, line widths etc. Another pass to produce the output.

One of the important parts of the first pass is to call dkfig_flat_list() to produce a flattened sorted list of Fig objects containing objects in order of drawing. Other tasks in the preparation pass are finding object bounding boxes and the bounding box for the entire drawing, information about used fonts, colors, fill patterns etc.


Generated on Tue Dec 1 08:45:40 2009 for fig2vect by  doxygen 1.5.8