AccordionDrawer
Class LabelBox
java.lang.Object
|
+--AccordionDrawer.LabelBox
- All Implemented Interfaces:
- java.lang.Comparable
- public class LabelBox
- extends java.lang.Object
- implements java.lang.Comparable
Axis-aligned bounding box class for label drawing. Stores
information in screen coordintes, checks for overlap with other
bounding boxes.
- Author:
- Tamara Munzner
Constructor Summary |
LabelBox(int[] bottomLeft,
int[] bottomRight,
int[] topLeft,
int[] topRight,
int[] bottomLeftBG,
int computedFrame,
java.lang.String name,
int labelheight,
double angle,
int drawVert)
|
LabelBox(int[] bottomLeft,
int[] topRight,
int[] bottomLeftBG,
int computedFrame,
java.lang.String name)
|
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
LabelBox
public LabelBox(int[] bottomLeft,
int[] topRight,
int[] bottomLeftBG,
int computedFrame,
java.lang.String name)
LabelBox
public LabelBox(int[] bottomLeft,
int[] bottomRight,
int[] topLeft,
int[] topRight,
int[] bottomLeftBG,
int computedFrame,
java.lang.String name,
int labelheight,
double angle,
int drawVert)
intersectBoxes
public boolean intersectBoxes(LabelBox b)
compareTo
public int compareTo(java.lang.Object o)
- implement Comparable interface - sort on y values
- Specified by:
compareTo
in interface java.lang.Comparable
compareBtoT
public boolean compareBtoT(LabelBox target,
int low,
int high)
bottomBiggerThanTop
public boolean bottomBiggerThanTop(LabelBox target)
pos
public int pos(int xy)
topRightPos
public int topRightPos(int xy)
getName
public java.lang.String getName()
- Returns:
size
public int size(int xy)