{
GVJ_t *job;
+ if (!GD_drawing(g)) {
+ fprintf(stderr, "Layout was not done. Missing layout plugins? \n");
+ return -1;
+ }
+
init_gvc_from_graph(gvc, g);
init_layering(gvc, g);
init_bb(g);
gvc->keybindings = gvevent_key_binding;
gvc->numkeys = gvevent_key_binding_size;
-/* gvc->active_jobs = NULL; acive job sets can straddle multiple input graphs */
- for (job = gvrender_first_job(gvc); job; job = gvrender_next_job(gvc)) {
+ for (gvrender_first_job(gvc); job; job = gvrender_next_job(gvc)) {
job->g = g;
if (!job->output_file) { /* if not yet opened */
job->output_lang = gvrender_select(job, job->output_langname);
if (job->output_lang == NO_SUPPORT) {
fprintf(stderr,"renderer for %s is unavailable\n", job->output_langname);
- return 1;
+ return -1;
}
job = gvc->job;
job->output_lang = gvrender_select(job, job->output_langname);
- if (!GD_drawing(g) && job->output_lang != CANONICAL_DOT) {
- fprintf(stderr, "Layout was not done\n");
- return -1;
- }
job->output_file = out;
gvRenderJobs(gvc, g);
{
gvlayout_engine_t *gvle = gvc->layout.engine;
+ if (! gvle)
+ return -1;
+
graph_init(g, gvc->layout.features->flags & LAYOUT_USES_RANKDIR);
GD_gvc(g) = gvc;
if (gvle && gvle->layout)