On Feb 17, 2006, at 10:51 AM, William Krick wrote:
Does it make any difference performance-wise if I design my app
using nested
views and layouts vs. explicit positioning using x and y?
I'm used to Java swing development where the mantra is "more
objects ==
slower" but I'm not sure if any thing similar exists in laszlo.
Layouts are (mostly) implemented with constraints; think of a layout
as a very nice bundle of very useful constraints. A change to a
property of a view in a layout will trigger a cascade of event
propagation. If it's a complex layout, you could be changing hundreds
of properties when you change one view's width. (Think of the first
view in a wrapping layout. What happens when you change its width?)
Nested views and layouts are good for rapid prototyping and crucial
for databinding or dynamic layouts. If your layout is static, though
-- like most swing ui's unless they use GridBagLayout -- then you'll
get equivalent-or-better performance if you lay things out explicitly
with x and y. *How much* better is a "your mileage may vary" thing.
Also, I think Max fixed a significant layout startup performance
issue in between 3.1.1 and 3.2.
benjamin shine
software engineer
[EMAIL PROTECTED]
_______________________________________________
Laszlo-user mailing list
[email protected]
http://www.openlaszlo.org/mailman/listinfo/laszlo-user