Sha256: 514b08c9f75ca4fde21644b1d5deb26e53f1065b92d1e3163c63aa1ec16b9a00

Contents?: true

Size: 431 Bytes

Versions: 13

Compression:

Stored size: 431 Bytes

Contents

$:.unshift( "../lib" );
require "graphviz"

graph = GraphViz.new( :G, :type => :digraph )

node1 = graph.add_node("hello:world", 
  "shape" => "record", 
  "label" => "<left>|<f1> 1|<right>" )

node2 = graph.add_node("2", 
  "shape" => "record", 
  "label" => "<left>|<f1> 2|<right>" )

graph.add_edge( {node1 => :left}, node2 )
graph.add_edge( {node2 => :right}, node1 )

puts graph.output( :none => String, :png => "#{$0}.png" )

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
ruby-graphviz-1.0.2 examples/sample40.rb
ruby-graphviz-1.0.1 examples/sample40.rb
ruby-graphviz-1.0.0 examples/sample40.rb
ruby-graphviz-0.9.21 examples/sample40.rb
ruby-graphviz-0.9.20 examples/sample40.rb
ruby-graphviz-0.9.19 examples/sample40.rb
ruby-graphviz-0.9.18 examples/sample40.rb
ruby-graphviz-0.9.17 examples/sample40.rb
ruby-graphviz-0.9.16 examples/sample40.rb
ruby-graphviz-0.9.15 examples/sample40.rb
ruby-graphviz-0.9.14 examples/sample40.rb
ruby-graphviz-0.9.13 examples/sample40.rb
ruby-graphviz-0.9.12 examples/sample40.rb