| java.lang.Object org.jfree.chart.plot.PieLabelRecord
PieLabelRecord | public class PieLabelRecord implements Comparable,Serializable(Code) | | A structure that retains information about the label for a section in a pie
chart.
|
Constructor Summary | |
public | PieLabelRecord(Comparable key, double angle, double baseY, TextBox label, double labelHeight, double gap, double linkPercent) Creates a new record. |
Method Summary | |
public int | compareTo(Object obj) Compares this object to an arbitrary object.
Parameters: obj - the object to compare against. | public double | getAllocatedY() Returns the allocated y-coordinate. | public double | getAngle() Returns the angle of the middle of the section, in radians. | public double | getBaseY() Returns the base y-coordinate. | public double | getGap() Returns the gap. | public Comparable | getKey() Returns the key for the section that the label applies to. | public TextBox | getLabel() Returns the label. | public double | getLabelHeight() Returns the label height (you could derive this from the label itself,
but we cache the value so it can be retrieved quickly). | public double | getLinkPercent() Returns the link percent. | public double | getLowerY() Returns the lower bound of the label. | public double | getUpperY() Returns the upper bound of the label. | public void | setAllocatedY(double y) Sets the allocated y-coordinate. | public void | setBaseY(double base) Sets the base y-coordinate. | public String | toString() Returns a string describing the object. |
PieLabelRecord | public PieLabelRecord(Comparable key, double angle, double baseY, TextBox label, double labelHeight, double gap, double linkPercent)(Code) | | Creates a new record.
Parameters: key - the section key. Parameters: angle - the angle to the middle of the section (in radians). Parameters: baseY - the base y-coordinate. Parameters: label - the section label. Parameters: labelHeight - the label height (in Java2D units). Parameters: gap - the offset to the left. Parameters: linkPercent - the link percent. |
compareTo | public int compareTo(Object obj)(Code) | | Compares this object to an arbitrary object.
Parameters: obj - the object to compare against. An integer that specifies the relative order of the two objects. |
getAllocatedY | public double getAllocatedY()(Code) | | Returns the allocated y-coordinate.
The allocated y-coordinate. |
getAngle | public double getAngle()(Code) | | Returns the angle of the middle of the section, in radians.
The angle, in radians. |
getBaseY | public double getBaseY()(Code) | | Returns the base y-coordinate. This is where the label will appear if
there is no overlapping of labels.
The base y-coordinate. |
getGap | public double getGap()(Code) | | Returns the gap.
The gap. |
getKey | public Comparable getKey()(Code) | | Returns the key for the section that the label applies to.
The key. |
getLabel | public TextBox getLabel()(Code) | | Returns the label.
The label. |
getLabelHeight | public double getLabelHeight()(Code) | | Returns the label height (you could derive this from the label itself,
but we cache the value so it can be retrieved quickly).
The label height (in Java2D units). |
getLinkPercent | public double getLinkPercent()(Code) | | Returns the link percent.
The link percent. |
getLowerY | public double getLowerY()(Code) | | Returns the lower bound of the label.
The lower bound. |
getUpperY | public double getUpperY()(Code) | | Returns the upper bound of the label.
The upper bound. |
setAllocatedY | public void setAllocatedY(double y)(Code) | | Sets the allocated y-coordinate.
Parameters: y - the y-coordinate. |
setBaseY | public void setBaseY(double base)(Code) | | Sets the base y-coordinate.
Parameters: base - the base y-coordinate. |
toString | public String toString()(Code) | | Returns a string describing the object. This is used for debugging only.
A string. |
|
|