Blank space after widget is not visible. [message #435287] |
Mon, 26 April 2004 18:38 |
Eclipse User |
|
|
|
Originally posted by: meerab.yahoo.com
Hello,
I am using GridLayout to display a form. The form makes some widget
controls "visible" and "invisible" based on user input.
I am observing that form is showing blank space for the controls that are
not visible. I am not able to get rid of the empty space. Has anyone faced
this issue? How to get rid of the blank space when the control is no
longer visible?
Pseudo code is..
// Add bannana
Text bannana = new Text(parent, SWT.Border);
bannana.setLayoutData( new GridData());
// Add mango
Text mango = new Text(parent, SWT.Border);
mango.setLayoutData( new GridData());
//... Some where down in the code..
if(userchoice == magno) {
bannana.setVisible(false);
mango.setVisible(true);
parent.pack(true);
}else {
bannana.setVisible(true);
mango.setVisible(false);
parent.pack(true);
}
** I see a blank link in the form display showing empty space for the
widget that has visibility "false" ***
Thanks for your help!!
-Meera
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.02775 seconds