So, I have this BorderLayout frame with a panel pnlLogo in North. In that panel I've got an image in a label. The problem is: I want to put it in the left upper corner of that north. But when I setLayout(null) and setbounds, the image doesn't show at all. In the normal flowlayout it does showup. Anyone who knows why?
package panels.components;
import java.awt.Color;
import javax.swing.*;
public class Logo extends JPanel{
// Declareren
public JLabel lblLogo;
public Logo(){
// Layout
this.setLayout(null);
this.setBackground(Color.decode("#414141"));
// Logo -> Label
ImageIcon image = new ImageIcon("src/media/Logo.jpg");
lblLogo = new JLabel("", image, JLabel.CENTER);
// Bounds
lblLogo.setBounds(10, 10, 210, 84);
// Panel
this.add(lblLogo);
}
}