explicitly attach them to the objects in a graph, either to
individual objects one at a time via \fBagbindrec\fP, or to
all the objects of the same class in a graph via \fBaginit\fP.
+(Note that for graphs, aginit is applied recursively to the
+graph and its subgraphs if rec_size is negative (of the
+actual rec_size.))
The \fBname\fP argument a record distinguishes various types of records,
and is programmer defined (Libcgraph reserves the prefix \fB_ag\fR).
If size is 0, the call to \fBagbindrec\fP is simply a lookup.
**********************************************************/
#include <stdio.h>
-#include <cgraph.h>
+#include <graphviz/cgraph.h>
static void prstats(Agraph_t * g, int verbose);
static void do_it(Agraph_t * g, int dostat);
{
Agnode_t *n;
Agedge_t *e;
+ Agraph_t *s;
+ int rec;
switch (kind) {
case AGRAPH:
+ rec = (rec_size < 0);
+ if (rec) rec_size = -rec_size;
agbindrec(g, rec_name, rec_size, mtf);
+ if (rec)
+ for (s = agfstsubg(g); s; s = agnxtsubg(s))
+ aginit(s,kind,rec_name,rec_size,mtf);
break;
case AGNODE:
case AGOUTEDGE: