Sha256: 9aac320f9f2525431aa9ed1e850286e370e76799490edd3b3e9fd8058cb9eaa9
Contents?: true
Size: 499 Bytes
Versions: 9
Compression:
Stored size: 499 Bytes
Contents
# = Dot and anchors # This example shows how looks differents positions of anchors on dots $:.unshift(File.dirname(__FILE__)+"/../lib") require 'rubyvis' vis = pv.Panel.new().width(200).height(200); dot=vis.add(pv.Dot) .data([1,2,3,4,5,6]) .bottom(lambda {|d| d*30}) .left(lambda { 20+index*40} ) .shape_radius(10) %w{top bottom left right center}.each do |dir| dot.anchor(dir).add(pv.Label).text(dir[0,1]) end vis.render() #puts vis.children_inspect puts vis.to_svg
Version data entries
9 entries across 9 versions & 1 rubygems