|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectonbon.bx06.area.unit.CompositeBxUnit
public class CompositeBxUnit
组合式单元。
Constructor Summary | |
---|---|
CompositeBxUnit(String name,
BxUnit... units)
建构子。 |
Method Summary | |
---|---|
void |
addHead(BxUnit unit)
在原本的单元最前增加新的单元。 |
void |
addTail(BxUnit unit)
在原本的单元最後增加新的单元。 |
Rectangle |
arrange(Rectangle container,
int x,
int y,
boolean center)
重整计算各单元的座标。 |
void |
draw(Graphics2D g2d)
绘制底图。 |
Font |
getFont()
取得字型。 |
Color |
getForeground()
取得前景色。 |
BxUnit[] |
getUnits()
被组合的单元。 |
int |
getX()
取得相对于时间区域 X 座标的 X 座标。 |
int |
getY()
取得相对于时间区域 Y 座标的 Y 座标。 |
void |
offsetX(int offset)
偏移 X 座标。 |
void |
offsetY(int offset)
偏移 Y 座标。 |
void |
preview(Graphics2D g2d,
int areaX,
int areaY)
绘制底图。 |
void |
setFont(Font font)
设定字型。 |
void |
setForeground(Color foreground)
设定前景色。 |
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public CompositeBxUnit(String name, BxUnit... units)
name
- 名称。units
- 被组合的单元。Method Detail |
---|
public void addHead(BxUnit unit)
unit
- 单元。public void addTail(BxUnit unit)
unit
- 单元。public void offsetX(int offset)
offset
- X 座标。public void offsetY(int offset)
offset
- Y 座标。public int getX()
public int getY()
public BxUnit[] getUnits()
public Font getFont()
public void setFont(Font font)
font
- 字型。public Color getForeground()
public void setForeground(Color foreground)
foreground
- 前景色。public Rectangle arrange(Rectangle container, int x, int y, boolean center)
container
- 原区域大小。x
- 此单元配置 X 座标。y
- 此单元配置 X 座标。center
- 置中。
public void preview(Graphics2D g2d, int areaX, int areaY)
g2d
- 图布。areaX
- 区域 X 座标。areaY
- 区域 Y 座标。public void draw(Graphics2D g2d)
g2d
- 图布。public String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |