159160161162163164165166167168
Color old = g.getColor(); g.setColor(getBackground()); g.fillRect(0, 0, getWidth(), getHeight()); ImageIcon nodeImage = getNodeImage(); nodeImage.paintIcon(this, g, 0, 0); g.setColor(old); } }
309310311312313314315316317318319
int leftSpaceOfClearIcon = 0; if (displayClearIcon) { ImageIcon icon = getClearIcon(); int margin = (height - icon.getIconHeight()) / 2; icon.paintIcon(c, g2d, x + width - margin - icon.getIconWidth(), y + margin); leftSpaceOfClearIcon = margin + icon.getIconWidth(); } if (displayRefreshIcon)
115116117118119120121122123124125
} } g2d.dispose(); // render image image.paintIcon(c, g, x, y); } }; }