@Override public int getIconHeight() { return entityIcon.getIconHeight() + 2; } }
@Override public int getIconHeight() { return entityIcon.getIconHeight() + 2; } }
@Override public int getIconHeight() { return entityIcon.getIconHeight() + 2; }
@Override public int getIconHeight() { return entityIcon.getIconHeight() + 2; } }
@Override public int getIconHeight() { return entityIcon.getIconHeight() + 2; } }
@Override public int getIconHeight() { return entityIcon.getIconHeight() + 2; } }
@Override public int getIconHeight() { return entityIcon.getIconHeight() + 2; } }
@Override public int getIconHeight() { return entityIcon.getIconHeight() + 2; }
@Override public void paintIcon(Component c, Graphics g, int x, int y) { Graphics2D g2 = (Graphics2D) g.create(); EntityActionIcon.setupAlpha(c, g2); try { int halfWidth = getIconWidth() / 2; int xC = halfWidth + x; int halfHeight = getIconHeight() / 2; int yC = halfHeight + y; entityIcon.paintIcon(c, g2, xC - (entityIcon.getIconWidth() / 2), yC - (entityIcon.getIconHeight() / 2)); g2.setStroke(EntityActionIcon.ACTION_STROKE); g2.setColor(entityIcon.getEntityColor()); int crossLegLen = 7; g2.drawLine(xC - crossLegLen, yC - crossLegLen, xC + crossLegLen, yC + crossLegLen); g2.drawLine(xC - crossLegLen, yC + crossLegLen, xC + crossLegLen, yC - crossLegLen); } finally { g2.dispose(); } }
@Override public void paintIcon(Component c, Graphics g, int x, int y) { Graphics2D g2 = (Graphics2D) g.create(); EntityActionIcon.setupAlpha(c, g2); try { int halfWidth = getIconWidth() / 2; int xC = halfWidth + x; int halfHeight = getIconHeight() / 2; int yC = halfHeight + y; entityIcon.paintIcon(c, g2, xC - (entityIcon.getIconWidth() / 2), yC - (entityIcon.getIconHeight() / 2)); g2.setStroke(EntityActionIcon.ACTION_STROKE); g2.setColor(entityIcon.getEntityColor()); int crossLegLen = 7; g2.drawLine(xC - crossLegLen, yC - crossLegLen, xC + crossLegLen, yC + crossLegLen); g2.drawLine(xC - crossLegLen, yC + crossLegLen, xC + crossLegLen, yC - crossLegLen); } finally { g2.dispose(); } }
g2.translate(cx0, cy0); int topSibX = -entityIcon.getIconWidth() / 2; int topSibY = -entityIcon.getIconHeight() / 2; int botSibY = -entityIcon.getIconHeight() / 2; g2.scale(scaleFactor, scaleFactor); entityIcon.paintIcon(c, g2, botSibX, botSibY);
g2.translate(cx0, cy0); int topSibX = -entityIcon.getIconWidth() / 2; int topSibY = -entityIcon.getIconHeight() / 2; int botSibY = -entityIcon.getIconHeight() / 2; g2.scale(scaleFactor, scaleFactor); entityIcon.paintIcon(c, g2, botSibX, botSibY);