Author Topic:   which layout can position components at exact location
shan
unregistered
posted February 20, 2000 08:33 PM           
which layout can position components at exact location
null layout
cardlayout
setlayout
borderlayout

Umesh
ranch hand
posted February 20, 2000 08:43 PM             
Borderlayout is the right choice in the list. I think Gridlayout and Gridbaglayout also right answer if it would have been in the list.

maha anna
bartender
posted February 20, 2000 09:51 PM             
null layout // I assume it means we are doing this container.setLayout(null); This means there is no LayoutManager assigned for this container. So whereever you place a comp it stays there itself and when you resize the container the components are not rearranged. You have to do the HARD WORK of the Layout Manager yourself. So this is the ANSWER

cardlayout // same as the reason given for borderlayout

setlayout //Not a valid layout

borderlayout // does not anchor a component in the same pos at all times. When the container is resized all the comp are relocated according to the layout policy.

Tony Alicea
sheriff
posted February 21, 2000 10:17 AM             
The null layout is used for this.

|