import javax.swing.*; import java.awt.*; public class MainFond { public static void main(String[] args) { JFrame frame = new JFrame("Fond"); frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); JPanel panel = new JPanel(); Fond test = new Fond(); frame.add(panel, BorderLayout.CENTER); frame.setSize(500,500); frame.setLocation(500,250); frame.setVisible(true); } }