dcsimg
calculate layouts 'bottom up'
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Wolfgang_Rostek
Posted On:   Tuesday, October 15, 2002 09:12 AM

I'm using the XmFormLayout manager (http://www.softbear.com/java/xmformlm/xmformlm.htm). It tries to layout the components relative to each other and to the container boundaries. If it cannot bin the components in one direction it is using the preferred layout size. I find it straightforward and it should become my preferred layout manager. One remaining problem I still see. In some windows the 'optimal' size (I use optimal to avoid confusion about preferred size) is not known until the size of the child components is elaborated. E.g. nested panels where the inner panel may have three or four text fields. This will vary depending on runtime info. W   More>>

I'm using the XmFormLayout manager (http://www.softbear.com/java/xmformlm/xmformlm.htm).
It tries to layout the components relative to each other and to the container
boundaries. If it cannot bin the components in one direction it is using the
preferred layout size. I find it straightforward and it should become my
preferred layout manager.


One remaining problem I still see.


In some windows the 'optimal' size (I use optimal to avoid confusion about
preferred size) is not known until the size of the child components is
elaborated. E.g. nested panels where the inner panel may have three or
four text fields. This will vary depending on runtime info.


What I think about is a two pass layout. The first time I can only elaborate
what could be bound. The preferred size of the container is not correct
during the first run but could be adjusted after that. In the second run
all preferred sizes used will have the optimal size. Finally the setSize()
of the window will be optimal as well.


I know from the old VA times that Scott is a specialist in that area. Do
you have any advices what I have to consider?


I wonder that I have never read about this 'bottom up' layout problem
before.


Regards

Wolfgang R.

   <<Less
About | Sitemap | Contact