Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to learn Java Swing and make GUIs quickly?

I've been coding in Java for the past year, and i think I have solid OO and basic OOD skills. I'm looking to build a Java GUI on-top of an existing project which is not complex, but I want to finish it as quick as possible. So I'm looking for an API that would abstract all the nitty gritty implementations and let me focus on the core of my minimal viable product.

I really prefer coding with eclipse and not wasting time trying to learn to get used to another IDE. What would you suggest I do?

like image 418
Tom Avatar asked Jun 23 '12 10:06

Tom


Video Answer


1 Answers

Here is the crash course in swing.

First thing to learn is the layout managers.This is the big hurdle, they are finicky things and you have to master them.

Second is listeners,without them nothing happens.

Third is the JComponents themselves,you will slowly learn them as you go along. I would recommend using NetBeans GUI builder to play with them and get a feel for them.

Note that most JComponents have different models you can use rather then the default.

Also the only difference between JPanels and JComponents that I can find is that JPanels have layout managers.

A good place for various swing hacks and tutorials is here:

 http://www.java2s.com/Tutorial/Java/0240__Swing/Catalog0240__Swing.htm

 http://www.java2s.com/Code/Java/Swing-Components/CatalogSwing-Components.htm
like image 59
adrix89 Avatar answered Oct 23 '22 10:10

adrix89