🔒 Locked
[java] Preferred GUI design method
Advertisement
Original Post
I'm interested to know how most people design the GUI in Java? Do you use GUI builders like Netbeans, or do you manually code them?
I've been writing GUIs in Java using Layout Managers, specifically BoxLayout, and quite frankly, its never caught on with me. GUI builders I've tried seem to work best when using the NULL layout. Using any other layout in a GUI builder just doesn't seem to work. I'm interested if anyone else feels that layout managers are a pain to use, and if there are any other alternatives?
[edited by - NuffSaid on December 7, 2002 7:50:56 PM]
For games I can imagine few situations where a LayoutManager is going to make much sense.
I like to handcode them GUIs, but haven't tried any other way of designing GUIs with java. I'm quite happy with BorderLayout in most cases. If you don't specify which layout you are using, I think it's just using the FlowLayout:
http://java.sun.com/j2se/1.4/docs/api/java/awt/FlowLayout.html
As longs a you just do small games, I don't think you really need to use anything but BorderLayout or BoxLayout, if any.
[edited by - hotohori on December 8, 2002 10:48:55 AM]
http://java.sun.com/j2se/1.4/docs/api/java/awt/FlowLayout.html
As longs a you just do small games, I don't think you really need to use anything but BorderLayout or BoxLayout, if any.
[edited by - hotohori on December 8, 2002 10:48:55 AM]
Hi,
I started creating GUIs armed only with TextPad and all went fine. Well ... until I tried NetBeans. It''s not that you couldn''t produce some c00l layout manually, it''s all about time.
Creating a JFrame (with a few inputs & some basic functionallity) manually can take some 15 minutes, but using some GUI builder it''s much faster - about three times faster for me.
The transition to GUI-builder creating the user interface was not easy. I refused to give up nursing the nice, small, innocent handcrafted components (hehe, but that''s how I really felt it those days)
But if you really have some idea (read - design), how that frame should look and what it should do, you''re better off with visual GUI creation.
I personally use NetBeans throughout my projects and also for the GUI.
have fun
Petr Stedry
I started creating GUIs armed only with TextPad and all went fine. Well ... until I tried NetBeans. It''s not that you couldn''t produce some c00l layout manually, it''s all about time.
Creating a JFrame (with a few inputs & some basic functionallity) manually can take some 15 minutes, but using some GUI builder it''s much faster - about three times faster for me.
The transition to GUI-builder creating the user interface was not easy. I refused to give up nursing the nice, small, innocent handcrafted components (hehe, but that''s how I really felt it those days)
But if you really have some idea (read - design), how that frame should look and what it should do, you''re better off with visual GUI creation.
I personally use NetBeans throughout my projects and also for the GUI.
have fun
Petr Stedry
Don''t get caught up being tied to a single layout manager on a single level. Layout managers were meant to be used together by nesting them inside one another.
Make it work, then
make it fast.
"I’m happy to share what I can, because I’m in it for the love of programming. The Ferraris are just gravy, honest!" --John Carmack: Forward to Graphics Programming Black Book
Make it work, then
make it fast.
"I’m happy to share what I can, because I’m in it for the love of programming. The Ferraris are just gravy, honest!" --John Carmack: Forward to Graphics Programming Black Book
Hi,
why not use GridBagLayout as much as possible?
If anyone likes to nest 4-7 layouts deep just to have a nice looking GUI, why spoil the fun? But I personally prefer not to spend all my time on pushing components around from one container to the next. And this all just to have this Flow-in-Border-in-Box-in-GridLayout frame look sooooo pretty.
NuffSaid> Some time ago, I tried JBuilder (I think it was v4) and it''s GUI builder was quite a lot better than that of NetBeans. But the code completion engine and many other features (error trackin, debugging & price
) were inferior, compared to NetBeans. And that''s why I use NetBeans now.
have a nice day
Petr Stedry
why not use GridBagLayout as much as possible?
If anyone likes to nest 4-7 layouts deep just to have a nice looking GUI, why spoil the fun? But I personally prefer not to spend all my time on pushing components around from one container to the next. And this all just to have this Flow-in-Border-in-Box-in-GridLayout frame look sooooo pretty.
NuffSaid> Some time ago, I tried JBuilder (I think it was v4) and it''s GUI builder was quite a lot better than that of NetBeans. But the code completion engine and many other features (error trackin, debugging & price
have a nice day
Petr Stedry
quote:
Original post by NuffSaid
I''m interested to know how most people design the GUI in Java? Do you use GUI builders like Netbeans, or do you manually code them?
I''ve been writing GUIs in Java using Layout Managers, specifically BoxLayout, and quite frankly, its never caught on with me. GUI builders I''ve tried seem to work best when using the NULL layout. Using any other layout in a GUI builder just doesn''t seem to work. I''m interested if anyone else feels that layout managers are a pain to use, and if there are any other alternatives?
[edited by - NuffSaid on December 7, 2002 7:50:56 PM]
It depends on what I doing. If I am writting something more complex I''ll use a program like JBuilder (personal edition) and draw GUI like you do in VB, but if it''s simple I''ll just write the code to use the layout managers myself.
I agree layout managers can be a pain, but I am unaware of any other way to setup a GUI with Java.
quote:
Original post by NuffSaid
I'm interested to know how most people design the GUI in Java? Do you use GUI builders like Netbeans, or do you manually code them?
I've been writing GUIs in Java using Layout Managers, specifically BoxLayout, and quite frankly, its never caught on with me. GUI builders I've tried seem to work best when using the NULL layout. Using any other layout in a GUI builder just doesn't seem to work. I'm interested if anyone else feels that layout managers are a pain to use, and if there are any other alternatives?
[edited by - NuffSaid on December 7, 2002 7:50:56 PM]
It depends on what I am doing. If I am writting something more complex I'll use a program like JBuilder (personal edition) and draw GUI like you do in VB, but if it's simple I'll just write the code to use the layout managers myself.
I agree layout managers can be a pain, but I am unaware of any other way to setup a GUI with Java.
Sorry about the double post
[edited by - prh99 on December 13, 2002 10:42:56 PM]
It maybe comfortable to you, the programmer, to put yourself the layout of the components without the aid of the managers. But remember your users probably won''t have the resolution you have, that''s the objective of the managers, handle the resizing for you. Believe me, your user will thank you if you have a program that does this. (Not like VB applications I did a long time ago, which you maximized but the components stood with the same size ¬_¬)
With the other question, I use Forte to do all the GUI part, I love using an IDE, it saves me so much time doing the GUI, and it does what I want, I really don''t understand the people who say the opposite. Perhaps the IDE
I also use JCreator for the non-GUI parts, mostly because it''s faster than Forte.
With the other question, I use Forte to do all the GUI part, I love using an IDE, it saves me so much time doing the GUI, and it does what I want, I really don''t understand the people who say the opposite. Perhaps the IDE
I also use JCreator for the non-GUI parts, mostly because it''s faster than Forte.
Topic Locked
This topic has been locked by a moderator. New replies are not allowed.
Sign in to reply to this topic.
Advertisement