title: How can i create a JButton?
body: <p>After creating the JButton and setting it to Visible I do not understand why I don't see it in the Window.. :/</p>
  
  <pre><code>import java.awt.Color;
  
  import javax.swing.JButton;
  import javax.swing.JFrame;
  
  public class Window extends JFrame{
  
      public static int width = 350;
      public static int height  = 480;
  
      public static void main (String args[]) {
          JFrame window = new JFrame();
          window.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
          window.setSize(width, height);
          window.setVisible(true);
          window.setTitle("Virtual World");
          window.setLocationRelativeTo(null);
          window.setResizable(false);
          window.getContentPane().setBackground(new Color(80,80,240));
  
          JButton enter = new JButton();
          enter.setVisible(true);
  
  
      }
  
  }       
  </code></pre>