New User problem: resizing panels [message #458523] |
Thu, 14 July 2005 14:09 |
Eclipse User |
|
|
|
Originally posted by: epetrone.bellsouth.net
I'm still fairly new to creating SWT GUIs and am having a problem with my
panels that I'm sure is something trivial, but I've not been able to solve
it.
If I put all my widgets as direct children of the application shell, then
with I resize the window the widgets adjust as I expect them too (text
fields get wider, etc). However, if I create a layer of composites as
children of the shell (to create more complex layouts), and make the
widgets children of the various composites, I lose the resizing. The outer
shell will resize, but the content (composites and widgets both) seem to
maintain their original size.
I'm sure I've either added something to the code that is interfering with
the resizing or have forgotten to add some snippet of code that is required.
Any thoughts?
Thanks,
Elaine
|
|
|
Re: New User problem: resizing panels [message #458655 is a reply to message #458523] |
Mon, 18 July 2005 16:09 |
Steve Northover Messages: 1636 Registered: July 2009 |
Senior Member |
|
|
Controls are either explicity positioned during resize by application code
(using Control.setBounds()) or by layouts (see the hierarchy Layout and
Composite.setLayout()). If neither of these mechanisms are used, then a
control will not move. There is an in depth article on SWT layouts
available on Eclipse.org.
"Elaine" <epetrone@bellsouth.net> wrote in message
news:db5rlv$d19$1@news.eclipse.org...
> I'm still fairly new to creating SWT GUIs and am having a problem with my
> panels that I'm sure is something trivial, but I've not been able to solve
> it.
>
> If I put all my widgets as direct children of the application shell, then
> with I resize the window the widgets adjust as I expect them too (text
> fields get wider, etc). However, if I create a layer of composites as
> children of the shell (to create more complex layouts), and make the
> widgets children of the various composites, I lose the resizing. The
outer
> shell will resize, but the content (composites and widgets both) seem to
> maintain their original size.
>
> I'm sure I've either added something to the code that is interfering with
> the resizing or have forgotten to add some snippet of code that is
required.
> Any thoughts?
>
> Thanks,
> Elaine
>
>
|
|
|
|
Powered by
FUDForum. Page generated in 0.03075 seconds