Node Sizes n Tulip

amy
2011-11-30
2013-04-20
  • amy
    amy
    2011-11-30

    I cant figure out how to change node sizes in graph drawings. I am trying to set the node size in the gml file that i import (sample below). But that doesnt seem to make any change.

    Is there some setting in the tool itself where I can change the node size? Changing the ViewSize property doesnt seem to make a difference either. Is there a button I need to press to make it render again with the new size?

    Thanks,
    Amy

     
  • bliako bliko
    bliako bliko
    2012-04-29

    I have noticed the same behaviour for my own homemade tpl files. The fix I found was that we 'viewLayout' property for each node needs to be added, e.g.
    the following file ignores node sizes:
    (tlp "2.0"
    (date "Apr 27 2012 22:49:07 BST")
    (comments "a metabolic network")
    ;
    (nodes 0 1 2)
    (edge 0 0 1) 
    (property 0 size "viewSize"
      (default "(1,1,1)" "(1,1,1)" )
      (node 0 "(100,100,10)")
      (node 1 "(50,50,10)") 
      (node 2 "(10,0,10)")  
    )
    )

    The following file notices node sizes:
    (tlp "2.0"
    (date "Apr 27 2012 22:49:07 BST")
    (comments "a metabolic network")
    ;
    (nodes 0 1 2)
    (edge 0 0 1) 
    (property 0 layout "viewLayout"
      (default "(1,1,1)" "()" )
      (node 0 "(0,0,0)")
      (node 1 "(1,0,0)")    
      (node 2 "(2,0,0)")    
    )
    (property 0 size "viewSize"
      (default "(1,1,1)" "(1,1,1)" )
      (node 0 "(100,100,10)")
      (node 1 "(50,50,10)")
      (node 2 "(10,0,10)")
    )
    )

    notice the position of 'viewLayout' and also that each node is there.