Videos
Hi there,
Is there anyone familiar with a good and decent tutorial course that covers all of the stuff in the Java Swing package? Most tutorials I find are related to the Applet module. However, in developing my game im making use of Swing. I keep running into issues because I do not fully understand how the classes work and I would like to learn more about it. Thank you in advance!
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
Well, actually the GUI Builder in Netbeans is your best bet to make a GUI really fast. You can do it in a matter of minutes if you have the picture in your head about how it's supposed to look like. After that, the only thing left to do is to bind it to your application; more specifically: make the ActionListeners of your buttons for example do whatever they should.
This of course depends on the application's size. If it's small, then making a GUI for it is easy. If, on the other hand, it has 2000 classes, then it can be more complicated, since the GUI will probably be more complicated.
If the application can be modelled as a Model-View-Controller architecture, that would help you a lot.