lib/rubyvis/mark/wedge.rb in rubyvis-0.2.2 vs lib/rubyvis/mark/wedge.rb in rubyvis-0.3.0
- old
+ new
@@ -11,10 +11,10 @@
attr_accessor_dsl :start_angle, :end_angle, :angle, :inner_radius, :outer_radius, :line_width, [:stroke_style, lambda {|d| Rubyvis.color(d)}], [:fill_style, lambda {|d| Rubyvis.color(d)}]
def self.defaults
a=Rubyvis.Colors.category20()
- Wedge.new.extend(Mark.defaults).start_angle(lambda {s=self.sibling; s ? s.end_angle: -Math::PI.quo(2) } ).inner_radius( 0 ).line_width( 1.5 ).stroke_style( nil ).fill_style( lambda {a.scale(self.index)})
+ Wedge.new.mark_extend(Mark.defaults).start_angle(lambda {s=self.sibling; s ? s.end_angle: -Math::PI.quo(2) } ).inner_radius( 0 ).line_width( 1.5 ).stroke_style( nil ).fill_style( lambda {a.scale(self.index)})
end
def mid_radius
(inner_radius+outer_radius) / 2.0
end
def mid_angle