non-integrated layout manager not laying out [message #45408] |
Thu, 01 July 2004 18:26  |
Eclipse User |
|
|
|
Originally posted by: Steve_Baker.moh.govt.nz
I have a project which uses these layout managers:
http://www.jhlabs.com/java/layout/index.html
especially GridLayoutPlus.
I don't need the layout managers to be integrated with eclipse, as long as
they render correctly.
With VE on Eclipse 2.1.2 this rendered fine but with VE S20040628 and
Eclipse 3 it always looks like its rendering with a flow layout and the
layout property says null.
I guess you could call this a regression - I would very much like to
migrate to V3 but this makes it tricky.
cheers
|
|
|
Re: non-integrated layout manager not laying out [message #45917 is a reply to message #45408] |
Fri, 02 July 2004 10:35   |
Eclipse User |
|
|
|
Originally posted by: richkulp.NO.SPAM.us.ibm.com
Make sure the name of the layout (when it is a separate variable) is
prefixed with "ivj" for now. That is the simplest way:
GridBagLayoutPlus ivjglp = new GridBagLayoutPlus(0, 3, 10, 10);
ivjglp.set...
jpanel.setLayout(ivjglp);
However, the settings like:
ivjglp.setColWeight(1, 2);
ivjglp.setColWeight(2, 1);
ivjglp.setRowWeight(2, 1);
will not be applied in the VE because they aren't properties, they are
methods. The editor doesn't know anything about methods, only
properties. (A property is a set method that takes only one argument,
such as setText(String)).
It will then work correctly at runtime. Without the "ivj" prefix it
doesn't know to model the declaration stmt, so the default flow layout
is used.
--
Thanks, Rich Kulp
|
|
|
Re: non-integrated layout manager not laying out [message #47176 is a reply to message #45917] |
Mon, 05 July 2004 18:59  |
Eclipse User |
|
|
|
Originally posted by: Steve_Baker.moh.govt.nz
Rich Kulp wrote:
> Make sure the name of the layout (when it is a separate variable) is
> prefixed with "ivj" for now. That is the simplest way:
That worked, thanks.
> However, the settings like:
> ivjglp.setColWeight(1, 2);
> ivjglp.setColWeight(2, 1);
> ivjglp.setRowWeight(2, 1);
> will not be applied in the VE because they aren't properties, they are
> methods. The editor doesn't know anything about methods, only
> properties. (A property is a set method that takes only one argument,
> such as setText(String)).
I can live with that. As long as it lays out in some grid like fashion.
|
|
|
Re: non-integrated layout manager not laying out [message #593654 is a reply to message #45408] |
Fri, 02 July 2004 10:35  |
Eclipse User |
|
|
|
Originally posted by: richkulp.NO.SPAM.us.ibm.com
Make sure the name of the layout (when it is a separate variable) is
prefixed with "ivj" for now. That is the simplest way:
GridBagLayoutPlus ivjglp = new GridBagLayoutPlus(0, 3, 10, 10);
ivjglp.set...
jpanel.setLayout(ivjglp);
However, the settings like:
ivjglp.setColWeight(1, 2);
ivjglp.setColWeight(2, 1);
ivjglp.setRowWeight(2, 1);
will not be applied in the VE because they aren't properties, they are
methods. The editor doesn't know anything about methods, only
properties. (A property is a set method that takes only one argument,
such as setText(String)).
It will then work correctly at runtime. Without the "ivj" prefix it
doesn't know to model the declaration stmt, so the default flow layout
is used.
--
Thanks, Rich Kulp
|
|
|
Re: non-integrated layout manager not laying out [message #594241 is a reply to message #45917] |
Mon, 05 July 2004 18:59  |
Eclipse User |
|
|
|
Rich Kulp wrote:
> Make sure the name of the layout (when it is a separate variable) is
> prefixed with "ivj" for now. That is the simplest way:
That worked, thanks.
> However, the settings like:
> ivjglp.setColWeight(1, 2);
> ivjglp.setColWeight(2, 1);
> ivjglp.setRowWeight(2, 1);
> will not be applied in the VE because they aren't properties, they are
> methods. The editor doesn't know anything about methods, only
> properties. (A property is a set method that takes only one argument,
> such as setText(String)).
I can live with that. As long as it lays out in some grid like fashion.
|
|
|
Powered by
FUDForum. Page generated in 0.03646 seconds