public abstract class AbstractPainter extends java.lang.Object implements HoverPainter
| 限定符和类型 | 字段和说明 |
|---|---|
protected XLayoutContainer |
container |
protected XCreator |
creator |
protected java.awt.Point |
hotspot |
protected java.awt.Rectangle |
hotspot_bounds |
| 构造器和说明 |
|---|
AbstractPainter(XLayoutContainer container)
构造函数
|
| 限定符和类型 | 方法和说明 |
|---|---|
protected void |
drawHotspot(java.awt.Graphics g,
int x,
int y,
int width,
int height,
boolean accept) |
protected void |
drawHotspot(java.awt.Graphics g,
int x,
int y,
int width,
int height,
java.awt.Color bColor,
boolean accept,
boolean drawBackground) |
protected void |
drawRegionBackground(java.awt.Graphics g,
int x,
int y,
int width,
int height,
java.awt.Color bColor,
boolean accept)
自适应布局那边渲染提示,要画整个背景,不是画边框
|
void |
paint(java.awt.Graphics g,
int startX,
int startY)
画初始区域
|
void |
setCreator(XCreator component)
当前要放置的组件
|
void |
setHotspot(java.awt.Point p)
当前焦点热点,即鼠标所在点
|
void |
setRenderingBounds(java.awt.Rectangle rect)
设置边界
|
protected java.awt.Point hotspot
protected java.awt.Rectangle hotspot_bounds
protected XLayoutContainer container
protected XCreator creator
public AbstractPainter(XLayoutContainer container)
container - 容器public void setHotspot(java.awt.Point p)
HoverPaintersetHotspot 在接口中 HoverPainterp - 焦点位置public void paint(java.awt.Graphics g,
int startX,
int startY)
public void setRenderingBounds(java.awt.Rectangle rect)
setRenderingBounds 在接口中 Painterrect - 位置public void setCreator(XCreator component)
HoverPaintersetCreator 在接口中 HoverPaintercomponent - 组件protected void drawHotspot(java.awt.Graphics g,
int x,
int y,
int width,
int height,
boolean accept)
protected void drawRegionBackground(java.awt.Graphics g,
int x,
int y,
int width,
int height,
java.awt.Color bColor,
boolean accept)
protected void drawHotspot(java.awt.Graphics g,
int x,
int y,
int width,
int height,
java.awt.Color bColor,
boolean accept,
boolean drawBackground)