Speed of LayoutManagers

S

Stefan Schmiedl

Greetings,

are there any speed comparisons between different layout managers?

Today I dabbled around with JGoodies.com's FormLayout and found that
it took 0.3s to open a sample layout, which took 0.4s when drawn with
NetBean's Matisse (FreeLayout?).

I am aware that different Layout Managers are intended for different
purposes, I just wondered if there was something like a "Grauert-Brief"
(standardized business letter often used for comparing printer speeds).

Thanks,
s.
 
T

Thomas Hawtin

Stefan said:
Today I dabbled around with JGoodies.com's FormLayout and found that
it took 0.3s to open a sample layout, which took 0.4s when drawn with
NetBean's Matisse (FreeLayout?).

Almost all of the time should be in get(Minimum|Preferred|Maximum)Size
calls. Hopefully these are only done once. I don't know why FormLayout
is faster, but perhaps it doesn't use all of them? A profiler might help.

Tom Hawtin
 
D

danharrisandrews

Hi Stefan,

I am not aware of any speed comparisons between layout managers. I am
aware though that the GridBagLayout that everyone loves to hate can be
lightning fast. According to Ethan Nicholas the "GridBagLayout is fast,
stable, and lets you program complicated layouts with a minimum of
components." Have a look at this link
(http://www.javalobby.org/java/forums/t1173.html) and part way down you
will see Ethan's tips. Two of those tips deal with layout managers.
Here is another link to Ethan's blog
(http://weblogs.java.net/blog/enicholas/archive/2006/04/reinventing_gri.html).

Cheers,

Dan Andrews

- - - - - - - - - - - - - - - - - - - - - - - -
Ansir Development Limited www.ansir.ca
- - - - - - - - - - - - - - - - - - - - - - - -
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,264
Messages
2,571,065
Members
48,770
Latest member
ElysaD

Latest Threads

Top