Class Scruffy::Layers::Pie
In: lib/scruffy/layers/pie.rb
Parent: Base

Scruffy::Layers::Pie

Author:A.J. Ostman
Date:August 15, 2006

Provides a container for pie slice.

Methods

legend_data   new   points=   render  

Included Modules

Scruffy::Helpers::LayerContainer

Constants

RADIANS = Math::PI/180   Setup Constants

Attributes

center_x  [RW] 
center_y  [RW] 
degree_offset  [RW] 
diameter  [RW] 
percent_used  [RW] 
scaler  [RW] 

Public Class methods

The initialize method passes itself to the block, and since Pie is a LayerContainer, layers (pie slice) can be added just as if they were being added to Graph.

Public Instance methods

A stacked graph has many data sets. Return legend information for all of them.

Overrides Base#render to fiddle with layers’ points to achieve a stacked effect.

[Validate]