g.setComposite(AlphaComposite.getInstance(AlphaComposite.SRC_OVER, 0.5f));
g.setColor(raised ? Color.WHITE : Color.BLACK);
g.fillPolygon(new int[]{0, getWidth() - 1, getWidth() - 1 - borderWidth, borderWidth},
new int[]{0, 0, borderHeight, borderHeight}, 4);
g.setColor(raised ? new Color(0xC0C0C0) : new Color(0x404040));
g.fillPolygon(new int[]{0, borderWidth, borderWidth, 0},
new int[]{1, borderHeight + 1, getHeight() - 1 - borderHeight, getHeight() - 1}, 4);
g.setColor(raised ? new Color(0x404040) : new Color(0xC0C0C0));
g.fillPolygon(new int[]{getWidth() - borderWidth - 1, getWidth() - 1, getWidth() - 1, getWidth() - borderWidth - 1},
new int[]{borderHeight + 1, 1, getHeight() - 1, getHeight() - 1 - borderHeight}, 4);
g.setColor(raised ? Color.BLACK : Color.WHITE);