Java-Gaming.org    
Featured games (81)
games approved by the League of Dukes
Games in Showcase (499)
Games in Android Showcase (118)
games submitted by our members
Games in WIP (568)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  Java GUI programming tutorial part 2  (Read 2349 times)
0 Members and 1 Guest are viewing this topic.
Offline CaptainJester

JGO Knight


Medals: 12
Projects: 2
Exp: 14 years


Make it work; make it better.


« Posted 2012-08-19 20:58:40 »

As mentioned in this thread, I am making a Java GUI tutorial. Part 2 is now up. You can access it at http://markbernard.wordpress.com/2012/08/19/java-gui-made-easy-part-2/

All comments are welcome, either here or in the tutorial post.

Offline Jimmt
« League of Dukes »

JGO Kernel


Medals: 133
Projects: 4
Exp: 3 years



« Reply #1 - Posted 2012-08-20 00:02:02 »

Looks good, however your code goes off the "paper" (white space) Grin.
Offline ReBirth
« Reply #2 - Posted 2012-08-20 03:00:02 »

I believe wordpress has code tags.

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline CaptainJester

JGO Knight


Medals: 12
Projects: 2
Exp: 14 years


Make it work; make it better.


« Reply #3 - Posted 2012-08-20 23:43:53 »

Thanks guys. Temporarily fixed code going off the screen. I haven't looked into Wordpress  tags yet. Will have to do that next.

Offline CaptainJester

JGO Knight


Medals: 12
Projects: 2
Exp: 14 years


Make it work; make it better.


« Reply #4 - Posted 2012-08-21 00:12:59 »

Ok. Found out how to highlight sourcecode properly for Wrodpress. Both posts have been updated.

Offline Cero
« Reply #5 - Posted 2012-08-21 00:37:46 »

btw is there anything equivalent to NetBeans's "Swing GUI Builder" for Eclipse ?
I found JFormDesigner, but its commercial.
Is WindowBuilder Pro good ?

Offline R.D.

Senior Member


Medals: 2
Projects: 1


"For the last time, Hats ARE Awesome"


« Reply #6 - Posted 2012-08-21 08:36:57 »

Eclipse has it's own Gui Builder now. Works for SWT or Swing (And some GWT magic too afair).
Imho the NetBeans's one is faster, the one in Eclipse is kinda slow on a lot of GUI-Elements (could be my laptop tho).
Offline sproingie

JGO Kernel


Medals: 202



« Reply #7 - Posted 2012-08-21 15:51:09 »

The netbeans gui builder (Matisse) has a very nice UI, but the code it generates is unmaintainable.  Eclipse's old VE had much nicer generated code, but the builder interface itself was a disaster.  I don't know about the code output of WBP, but it has to be better than Matisse.

Offline gene9

Senior Member


Medals: 10



« Reply #8 - Posted 2012-08-21 17:07:53 »

As mentioned in this thread, I am making a Java GUI tutorial. Part 2 is now up. You can access it at http://markbernard.wordpress.com/2012/08/19/java-gui-made-easy-part-2/

All comments are welcome, either here or in the tutorial post.

Swing has been completely superseded by JavaFX already. Why would you work on new tutorials on Swing at this point?

It still makes sense to use Swing as a shim to a bare-bones canvas or OpenGL context, but actually doing menus and Swing components in a non-legacy codebase doesn't make sense any more.
Offline gimbal

JGO Knight


Medals: 25



« Reply #9 - Posted 2012-08-21 18:35:35 »

Swing has been completely superseded by JavaFX already. Why would you work on new tutorials on Swing at this point?

Not entirely, JavaFX is still lacking useful GUI components and on top of that: it is lacking a solid documentation base (quickly growing though). Swing still has its uses, even if they quickly reduce to "quick & dirty" kind of stuff.

As to why: I guess it is "because I can".
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline gene9

Senior Member


Medals: 10



« Reply #10 - Posted 2012-08-21 22:07:26 »

Not entirely, JavaFX is still lacking useful GUI components and on top of that: it is lacking a solid documentation base (quickly growing though). Swing still has its uses, even if they quickly reduce to "quick & dirty" kind of stuff.

What useful GUI components is JavaFX lacking? It seems to have all the basics. I wrote a JavaFX app and the API docs seemed fine. There is a dearth of code examples on the Internet, of course.
Offline CaptainJester

JGO Knight


Medals: 12
Projects: 2
Exp: 14 years


Make it work; make it better.


« Reply #11 - Posted 2012-08-21 23:38:44 »

Part of this is also an exercise for me in writing. I know Swing a lot better than JavaFX. I also haven't been following that JavaFX has been brought into Java 7 as part of desktop UI. I thought it was still just for web UIs. So once I finish the Swing part I am going to write it in JavaFX so I can learn the ins and outs of JavaFX.

Offline StumpyStrust
« Reply #12 - Posted 2012-08-21 23:51:07 »

Idk. I feel like javaFX is just reinventing the wheel to run a little better. If people already know how to use Swing to do all sorts of thing, why switch to javaFX? Is it that much of performance/work flow boost?

Offline nsigma
« Reply #13 - Posted 2012-08-22 09:27:27 »

I also haven't been following that JavaFX has been brought into Java 7 as part of desktop UI.

Strictly speaking, it's shipped with Oracle's Java, but not planned to be a core part of Java SE until Java 9.  Swing isn't going anywhere (possibly in both senses!  Wink ) for a while.

Praxis LIVE - open-source intermedia toolkit and live interactive visual editor
Digital Prisoners - interactive spaces and projections
Offline gimbal

JGO Knight


Medals: 25



« Reply #14 - Posted 2012-08-22 19:11:00 »

Not entirely, JavaFX is still lacking useful GUI components and on top of that: it is lacking a solid documentation base (quickly growing though). Swing still has its uses, even if they quickly reduce to "quick & dirty" kind of stuff.

What useful GUI components is JavaFX lacking?

Actually after making that statement (that's the way to do it - first moan and then verify) I was checking over the JavaFX 2.2 docs and I must say it looks pretty complete now. I was leaning on my memories of JavaFX 2.0 to be honest.
Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

Pippogeek (40 views)
2014-09-24 16:13:29

Pippogeek (31 views)
2014-09-24 16:12:22

Pippogeek (21 views)
2014-09-24 16:12:06

Grunnt (47 views)
2014-09-23 14:38:19

radar3301 (29 views)
2014-09-21 23:33:17

BurntPizza (65 views)
2014-09-21 02:42:18

BurntPizza (37 views)
2014-09-21 01:30:30

moogie (44 views)
2014-09-21 00:26:15

UprightPath (53 views)
2014-09-20 20:14:06

BurntPizza (55 views)
2014-09-19 03:14:18
List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06

List of Learning Resources
by SilverTiger
2014-07-31 11:54:12

HotSpot Options
by dleskov
2014-07-08 01:59:08
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!