Solved

Quick Java Standalone Apps

Posted on 2006-11-20
9
197 Views
Last Modified: 2010-03-31
I am looking to write a Java standalone app that I want to work on OS X and Windows in particular. I do worry about the interface being too slow though. I have used some SWING interfaces and they are quick lethargic. Are there any native APIs that I could use to make the program run faster on certain platforms and reserve the slower workhorse versions for *nix?
0
Comment
Question by:dignified
  • 5
  • 4
9 Comments
 
LVL 24

Accepted Solution

by:
sciuriware earned 125 total points
ID: 17977655
You could try SWT as a replacement for SWING.
You can find it at www.eclipse.org

But I wonder if it will be faster.
I found over the years that slow SWING is a matter of bad programming.

;JOOP!
0
 
LVL 24

Expert Comment

by:sciuriware
ID: 17977666
... by bad programming I don't mean 'stupid' programming!
It's just that slow SWING is caused by SWING itself:
it's not intuitively set up. In the beginning you take wrong decisions.
I learned a lot from the JAVA SWING tutorial (SUN) and some good books.
Since then I wrote huge SWING applications with up to 200 threads,
each with their own components on screen, and it was fast enough.

;JOOP!
0
 

Author Comment

by:dignified
ID: 17977713
Are there any other Java GUI API that I could use?
0
 
LVL 24

Expert Comment

by:sciuriware
ID: 17977802
There's still X-windows, but I don't like the construction.
Funny, all we have about Windows comes from X-windows (XEROX, who adopted it in 1968),
but the approach looks clumsy now.
I would go for a thorough revision of your GUI and choose between SWING and SWT.

;JOOP!
0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 

Author Comment

by:dignified
ID: 17977866
I have done nothing more than a Hello World with SWING so far, but I have seen some cool looking java interfaces that looking nothing like the default SWING interface. Is it possible to change the looks of the buttons and things in SWING?
0
 
LVL 24

Expert Comment

by:sciuriware
ID: 17978162
Yes, start in SWING and then:
1) change the look and fonts of the components; there is a list of some 80 different sub-components you can customise,
2) try other lookandfeels,
3) try some public domain lookandfeels, like from http://www.jgoodies.com/
4) buy a 3rd party commercial lookandfeel.

Important: when your source code follows SWING you can switch lookandfeels, even while running.

;JOOP!
0
 

Author Comment

by:dignified
ID: 17995250
Is SWT what the eclipse gui is made from? I have heard good things about it and SWT.
0
 
LVL 24

Expert Comment

by:sciuriware
ID: 17995789
Yes
0
 

Author Comment

by:dignified
ID: 18006160
I think I will try SWT, everyone I have talked to uses it instead of SWING.
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

Suggested Solutions

For customizing the look of your lightweight component and making it look lucid like it was made of glass. Or: how to make your component more Apple-ish ;) This tip assumes your component to be of rectangular shape and completely opaque. (COD…
Java contains several comparison operators (e.g., <, <=, >, >=, ==, !=) that allow you to compare primitive values. However, these operators cannot be used to compare the contents of objects. Interface Comparable is used to allow objects of a cl…
Video by: Michael
Viewers learn about how to reduce the potential repetitiveness of coding in main by developing methods to perform specific tasks for their program. Additionally, objects are introduced for the purpose of learning how to call methods in Java. Define …
Viewers will learn about if statements in Java and their use The if statement: The condition required to create an if statement: Variations of if statements: An example using if statements:

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now