public void paint(Graphics g) {
if (_selected) {
g.setColor(SystemColor.textHighlight);
} else if(getParent() != null) {
g.setColor(getParent().getBackground());
} else {
g.setColor(getBackground());
}
Icon icon = getIcon();
int offset = 0;
if (icon != null && getText() != null) {
offset = icon.getIconWidth() + getIconTextGap();
}
g.fillRect(offset, 0, getWidth() - 1 - offset, getHeight() - 1);
super.paint(g);
}
TableTreeCellRenderer.java 文件源码
java
阅读 22
收藏 0
点赞 0
评论 0
项目:typecast
作者:
评论列表
文章目录