IWETHEY v. 0.3.0 | TODO
1,095 registered users | 1 active user | 0 LpH | Statistics
Login | Create New User
IWETHEY Banner

Welcome to IWETHEY!

New Java gui builders, do you use them?
I started with Java in 1997, before they existed and therefore, learned to build gui's in Java by hand. I find that I actually understand how the gui's work, while those who use teh GUI builder have no clue and cannot figure out why things don't work. I also find that the hand written code is 100x more readable and it encourages much better OO development.

Some examples, when building an application that will have a bunch of windows, I always create a Window superclass which takes care of the standard menu items, window close, etc. this gives all the windows the same look and feel. Likewise, many times the same panel is displayed in a number of places (e.g. customer information). In a hand written gui it can be re-used.

Another good example is layouts. Most gui builders either use absolute layout (which breaks as soon as you resize the window) or 1 big GridBagLayout. Again this is very unOO. If you make 1 change to the gui, it ripples throughout the whole window. I have found that using nested panels works much better, each panel's layout is encapsulated and protected from the rest, I can easily change how 1 panel looks without affecting the others a bit.

Gui builders use the standard inner class event listener pattern. While this is not a poblem for a small application, for large applications, this generates hundreds of inner class files. There are a number of other alternatives (GenericListener using proxies, or a listener using reflection) which require the creation of 1 or a few classes.

Last but not least, the generated code is very hard to read and is only really useful in the same IDE. Someone in my group used Forte for Java to generate a relatively simple screen, Forte generated an initComponents method 238 lines long (of course the whole window using 1 big GridBagLayout).

What does everyone else here think about the subject?
New Better to first ask...
... do you build GUIs in Java... ;-)

I don't. :-)
Regards,

-scott anderson

"Welcome to Rivendell, Mr. Anderson..."
New Hell NO
They suck to a one. OTOH, I also use soft binding (key value coding adaptors) to the whole mess. I can whip up a new dialog in a short period of time and have some lovely Table and List Models that make binding via keypaths a snap.

OTOH, when doing Cocoa development in ObjectiveC, I do use InterfaceBuilder. It rocks - but it doesn't generate code. It creates serialized object archives. When working with this, you just say something like NSBundle loadNibNamed: @"MyArchive" owner: self and it reinflates the archive using self as the "files owner" object in the archive. That rocks and the geometry management is better than the java layout managers (of which I only use Box, Flow, and Border - you can do anything at all with those).
I am out of the country for the duration of the Bush administration.
Please leave a message and I'll get back to you when democracy returns.
New No choice
My development team consists of PowerBuilder developers. We are starting to move to Java and when I mentioned we don't need GUI builders, a revolt nearly started.

Unfortunately, my favorite IDE (Eclipse) does not come with a GUI builder. Since I can't live without Eclipse, we are building the GUI using the NetBeans GUI Builder and doing the rest of development in Eclipse.

I have found I can create GUIs a lot faster using a GUI builder. NetBeans allows you to use any layout manager and to embed them. It also allows you to add your own custom controls to it's component palette, so I can create custom components and make them available for other developers.

I'm hoping the GUI builders are going to move towards using the XMLEncoder to save the interfaces instead of spitting out 100s of lines of ugly code. Maybe someday...

Regards,
John
New Java can do GUI's? >:)
Viva la HTML!

Many fears are born of stupidity and ignorance -
Which you should be feeding with rumour and generalisation.
BOfH, 2002 "Episode" 10
     Java gui builders, do you use them? - (bluke) - (4)
         Better to first ask... - (admin)
         Hell NO - (tuberculosis)
         No choice - (johnu)
         Java can do GUI's? >:) - (tseliot)

Up is down. Left is right. Black licorice tastes good.
38 ms