[nbdev] Re: It has been too long, I need a GUI Builder hint

  • From: Gregg Wonderly < >
  • To:
  • Cc: budcurtis < >
  • Subject: [nbdev] Re: It has been too long, I need a GUI Builder hint
  • Date: Wed, 17 Apr 2013 08:04:54 -0500

On 4/16/2013 10:06 PM, budcurtis wrote:
It has been a couple years since I did any java programing so I decided to go back to 
the examples as a refresher.  I want to write a Swing/AWT GUI and started with the 
NetBeans "Introduction to GUI Building" example.  I understand event handlers 
and the UI container scheme.  I used the Designer to add the components and modified 
the handlers as specified in the example.  I looked at the initComponents method, and 
it all looks OK. It builds and runs with no reported issues.

There is only one problem. While it sits there running, nothing is visible.  
I have checked the entire desktop by minimizing all the other running Apps 
including the IDE.   I'm running it from the IDE and it shows the demo to be 
running in the Output Panel of the IDE.  Does any one have any suggestion on 
what code I'm missing?  [Question]  Do I have to do something to make it 
visible?

Did you create a JFrame or JDialog as the "Window" component? Do you do anything to make it visible?

        // make all of the components resize to their preferred size
        frame.pack();
        // center it on the display
        frame.setLocationRelativeTo(null);

        // make it visible
        frame.setVisible(true);

Gregg Wonderly


[nbdev] It has been too long, I need a GUI Builder hint

budcurtis 04/17/2013

[nbdev] Re: It has been too long, I need a GUI Builder hint

Gregg Wonderly 04/17/2013

[nbdev] It has been too long, I need a GUI Builder hint

budcurtis 04/17/2013

Project Features

About this Project

www was started in November 2009, is owned by jpirek, and has 21 members.
By use of this website, you agree to the NetBeans Policies and Terms of Use (revision 20140418.2d69abc). © 2013, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo
 
 
Close
loading
Please Confirm
Close