Danke ^^ Und kann ich das JPanel auch nur Halbtransparent machen?? Das wäre optimal!!
panel = new JPanel() {
/*
* The panel is transparent but we want to paint the background
* to give it a semi transparent look.
*/
@Override
protected void paintComponent(Graphics g) {
g.setColor(getBackground());
g.fillRect(0, 0, getSize().width, getSize().height);
}
};
panel.setOpaque(false);
// set a semi transparent background Color:
panel.setBackground(new Color(0, 0, 255, 100));