]> granicus.if.org Git - graphviz/commitdiff
Xue's print out request has been implemented
authorarif <devnull@localhost>
Mon, 9 Nov 2009 23:18:02 +0000 (23:18 +0000)
committerarif <devnull@localhost>
Mon, 9 Nov 2009 23:18:02 +0000 (23:18 +0000)
cmd/smyrna/gui/beacon.c

index 8ac8c9a179a3e2f504ccf663f8d84b834ff8a3d1..26000d85b656cace5853fc615f51acac5c81e654 100644 (file)
@@ -206,6 +206,29 @@ int remove_from_pick_list(topview_node * n)
     }
     return 0;
 }
+static void print_node(topview_node * n)
+{
+    int ind=0;
+    char* val;
+    attr_list* l=view->Topview->attributes;
+    printf("Node Summary\n",);
+    printf("-------------\n",);
+    printf("name: %s\n",agnameof(n->Node));
+    for (;ind < l->attr_count;ind ++)
+    {
+       if(l->attributes[ind]->propagate)
+       {
+           val=agget(n->Node,l->attributes[ind]->name);
+           if (val)
+           {
+               printf("%s: %s\n",l->attributes[ind]->name,val);
+
+           }
+       }
+    }
+    printf("-------------\n",);
+
+}
 
 int add_to_pick_list(topview_node * n)
 {
@@ -215,6 +238,8 @@ int add_to_pick_list(topview_node * n)
                sizeof(topview_node *) * view->Topview->picked_node_count);
     view->Topview->picked_nodes[view->Topview->picked_node_count - 1] = n;
     select_node(n);
+    print_node( n);    
+
     return 1;
 }