x, y, Color.YELLOW, x + 50, y, Color.WHITE);
g2.setPaint(gradient);
int[] xcoords = { x + 10, x, x + 50, x + 40 };
int[] ycoords = { y, y + 50, y + 50, y };
GeneralPath polygon = new GeneralPath(GeneralPath.WIND_EVEN_ODD, xcoords.length);
polygon.moveTo(x + 25, y);
for (int i = 0; i < xcoords.length; i++)
{
polygon.lineTo(xcoords[i], ycoords[i]);
}
polygon.closePath();