public abstract class BxUnit extends Object
Constructor and Description |
---|
BxUnit(int x,
int y,
Bx5GScreenProfile screenProfile)
建构子。
|
Modifier and Type | Method and Description |
---|---|
int |
calculateUnitWidth(Graphics2D g2d)
利用画布计算宽度。
|
void |
darw(Graphics2D g2d)
绘图。
|
abstract byte[] |
generate()
产生单元位元组资讯。
|
Font |
getFont()
取得单元显示内容字型。
|
Bx5GScreenProfile |
getScreenProfile()
取得显示屏类型。
|
Color |
getUnitColor()
取得单位颜色。
|
int |
getUnitX()
取得相对于时间区域 X 座标的 X 座标。
|
int |
getUnitY()
取得相对于时间区域 Y 座标的 Y 座标。
|
abstract void |
preview(Graphics2D g2d,
int areaX,
int areaY)
绘图。
|
void |
setFont(Font font)
设定单元显示内容字型。
|
void |
setUnitColor(Color unitColor)
设定单位颜色。
|
void |
setUnitX(int unitX)
设定相对于时间区域 X 座标的 X 座标。
|
void |
setUnitY(int unitY)
设定相对于时间区域 Y 座标的 Y 座标。
|
public BxUnit(int x, int y, Bx5GScreenProfile screenProfile)
x
- 相对于时间区域 X 座标的 X 座标。y
- 相对于时间区域 Y 座标的 Y 座标。screenProfile
- 屏幕规格。public Bx5GScreenProfile getScreenProfile()
public int getUnitX()
public void setUnitX(int unitX)
unitX
- X 座标。public int getUnitY()
public void setUnitY(int unitY)
unitY
- 单元 Y 座标。public Font getFont()
public void setFont(Font font)
font
- 字型。public Color getUnitColor()
public void setUnitColor(Color unitColor)
unitColor
- 颜色。public int calculateUnitWidth(Graphics2D g2d)
g2d
- 画布。public void darw(Graphics2D g2d)
g2d
- 图布。public abstract void preview(Graphics2D g2d, int areaX, int areaY)
g2d
- 图布。areaX
- 区域 X 座标。areaY
- 区域 Y 座标。public abstract byte[] generate()
Copyright © 2020 onbon4j. All rights reserved.