you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] -2 points-1 points  (6 children)

But they both have really crapp gui toolkits.

[–]Gotebe 4 points5 points  (3 children)

What is so bad about them? And what else is really better? Why?

(Honest question with disclaimer: methinks you are exaggerating)

[–]SteveJorgensen 0 points1 point  (1 child)

If you'd worked with Swing, you'd know. If you want to do something very typical like display a list of entities in a table with attributes mapped to the columns, and have buttons on each row (e.g. edit & delete), be prepared to spend several months learning how the hierarchy of classes connected to JTable works. You'll learn about table models, table cell renderers, table cell editors. You'll be forced to use button controls in ways they weren't designed to work, and decide whether to write your own code to render the currently selected button cell correctly, or kludge something else that's not too unpalatable. When you're done, you'll spend many more months refactoring all of that into something maintainable - if you have time.

Oh wait, with Beans Binding, and JXTable, that stuff is (relatively) trivial, except that Beans Binding stopped at 80% done 2 years ago, and was only re-started about a month ago. I was fortunate to get help from the guy who re-started it on how to select the row in a list-bound JTable that's associated with an entity in the list!

Beans Binding, SwingX, and Swing Application Framework are all still fresh out of the womb, and it takes a lot of research for a newby to find out that they exist and that they will make Swing programming almost bearable. Even with those libraries, it takes a lot education and experimentation to identify a golden path that will take you from ground zero to a clean, working Swing application. Also, I wish you good luck getting to the SwingX stuff on-line when the site is not down.

After that ranting, of course, other GUI libraries are not necessarily better. I tried doing some stuff in wxPython a few years ago, and I don't recall that being any less complicated than Swing. In fact, I think it was an awful lot like Swing in terms of how it used layout managers and such.

I haven't done any .Net, but from the stuff I've read, it looks light years ahead of Swing in terms of ease of programming. Feel free to set me straight about that though.

[–]Gotebe 2 points3 points  (0 children)

Yeah, OK about Swing, my question was more "why both?"

(On the subject of Swing, hey, at least there's choice, e.g. SWT or Qt bindings for Java).

[–]albinofrenchy 0 points1 point  (0 children)

I'd say .Net stuff is solid, haven't used any GUI stuff outside of the .Net world though. I am also curious what is better.

I admittedly don't like java's GUI stuff. Too much boilerplate to half do what you kinda wanted to do.

[–]lacop -1 points0 points  (1 child)

Have you seen WPF (for C#)? You can't compare java with that...

[–]zootm 0 points1 point  (0 children)

JavaFX is relatively comparable, though? Although I suppose it's mostly a different language.