• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Paul Clapham
  • Ron McLeod
Sheriffs:
  • Jeanne Boyarsky
  • Liutauras Vilda
Saloon Keepers:
  • Tim Holloway
  • Carey Brown
  • Roland Mueller
  • Piet Souris
Bartenders:

How can I make this application look like a windows application?

 
Ranch Hand
Posts: 86
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello everyone,
I have this application I developed, it's like a text editor and it's really nice but it has one flaw. When a user clicks on the Help menu and then on "About this software", I would have loved it if this brought up the kind of box you see when you perform a similar action on any windows application. Instead, a menuItem in which am trying to describe the software comes up and it streaches past the length of the screen. When this menuitem is selected, the actionPerformed() is coded to bring up the menuitem createed by this line of code
I've tried to create a panel/canvas that can come up the way windows does without success. Can anyone please tell me how to get the results I'm trying to achieve?
Thanks.
 
Ranch Hand
Posts: 262
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What problem did you encounter when you tried to create and display a new panel?
 
Sheriff
Posts: 3064
12
Mac IntelliJ IDE Python VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I may not be seeing the whole picture here, but if you want to bring up your autobiography in a panel, why not put it in a panel? Then put the panel on the dialog and show or hide it as appropriate. If you put it in a menu item, of course it appears in the menu and stretches across the screen as you describe.
 
Ranch Hand
Posts: 124
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello Femi ,
U can create another class extending from Dialog or JDialog and ur problem will be solved.
All u need to do is On click of the button initiate the new class which extends from Dialog
and set its VSisible property to true. and give some size.
 
Femi Alla
Ranch Hand
Posts: 86
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for your responses. I'm grateful.
Give me a day to try these out and I'll get back to you.
Thanks for the ideas.
 
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If you want to make your application look like
a windows application then just set the
look and feel in the UI manager to windows
Heres some sample code......

String windows = "com.sun.java.swing.plaf.windows.WindowsLookAndFeel";
try {UIManager.setLookAndFeel(windows);}
catch (Exception exc) {System.err.println("Error loading L&F: " + exc);}
By the way, this will only work on a windows platform.
Not sure though if this is what you wanted.
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic