Tuesday, December 30, 2008

Getting Started with Swing

Getting Started with Swing is the first lesson in the so-called Swing Tutorial. The lesson has two parts: About the JFC and Swing and Compiling and Running Swing Programs.

The first is as dull as it sounds, albeit of theoretical importance. It is essentially a reminder of the transparency of Java - a reminder that the power of Java lies in the huge collection of classes, already written by someone else, but made available for everyone. So while you can use a development environment like NetBeans, you can also access the functionality of the classes with hand written code.

This is important. If you want to program in VB (to create a Windows app) but you don't like the development environment, you are pretty well buggered. But if you want to create a GUI with Java, and you don't like NetBeans, you can either use another development environment, or you can do the whole thing with a text editor, provided you follow the rules very carefully.

The second part of the lesson is also very dull (another sodding "Hello World" variant), but it includes a moderately interesting link in small print. This is Running Tutorial Examples in NetBeans IDE. A link is provided to download NetBeans (for anyone who missed the riveting "Hello World!" for the NetBeans IDE). After installing NetBeans, you can download one or more example projects. Instructions are then provided on how to load a project into NetBeans, and from there compile it and run it.

No comments: