public void paintBackground(Container parent, Graphics g, int x, int y, int height) { if (getBackgroundColor() != null) { g.setColor(getBackgroundColor()); g.fillRect(x, y, getWidth(), height); } if (getBackgroundImage() != null) { GUI.tileImage(getBackgroundImage(), g, x, y, getWidth(), height); } }