if (!gvc || !t || !h)
return NULL;
#ifdef WITH_CGRAPH
+ // edges from/to the protonode are not permitted
+ if (AGTYPE(t) == AGRAPH || AGTYPE(h) == AGRAPH)
+ return NULL;
return agedge(agraphof(t), t, h, NULL, 1);
#else
// edges from/to the protonode are not permitted
{
if (!t || !h)
return NULL;
+#ifndef WITH_CGRAPH
+ if (AGTYPE(t) == AGRAPH || AGTYPE(h) == AGRAPH)
+ return NULL;
+#endif
return agfindedge(agraphof(t), t, h);
}
{
if (!e)
return NULL;
+#ifndef WITH_CGRAPH
+ if (AGTYPE(e) == AGRAPH)
+ return NULL;
+#endif
return aghead(e);
}
{
if (!e)
return NULL;
+#ifndef WITH_CGRAPH
+ if (AGTYPE(e) == AGRAPH)
+ return NULL;
+#endif
return agtail(e);
}
{
if (!e)
return NULL;
+#ifndef WITH_CGRAPH
+ if (AGTYPE(e) == AGRAPH)
+ return (Agraph_t*)e; /* graph of protoedge is itself recast */
+#endif
return agraphof(agtail(e));
}
{
if (!n)
return NULL;
+#ifndef WITH_CGRAPH
+ if (AGTYPE(e) == AGRAPH)
+ return (Agraph_t*)n; /* graph of protonode is itself recast */
+#endif
return agraphof(n);
}
{
if (!n)
return NULL;
+#ifndef WITH_CGRAPH
+ if (AGTYPE(n) == AGRAPH)
+ return NULL;
+#endif
return agnameof(n);
}
//char *nameof(Agedge_t *e)
//{
// if (!e)
// return NULL;
+//#ifndef WITH_CGRAPH
+// if (AGTYPE(e) == AGRAPH)
+// return NULL;
+//#endif
// return agnameof(e);
//}
char *nameof(Agsym_t *a)