PDA

View Full Version : FormPanel border



hiinsu
12 Jul 2010, 8:35 AM
Hi,

for a form panel, setBorders(false) does not work.
so I have been using setBodyBorder(false), and getHeader().setBorders(false) or setHeaderVisible(false) to disable borders on a form panel
what I noticed is that this seem to conflic with GXT messages.
ie. if i use formPanel.mask(GXT.MESSAGES,loadMask_msg());
form breaks down.

is there an alternative?

oxyrox
12 Jul 2010, 12:10 PM
Just tried this and worked like a charm.

Do you have a testcase or a screenshot?

Here's my testcase for this:

public class GxtTestEntryPoint implements EntryPoint {

public GxtTestEntryPoint() {
}

public void onModuleLoad() {
Viewport viewport = new Viewport();
LayoutContainer container = new LayoutContainer(new FitLayout());
container.setSize(500, 500);

FormPanel form = new FormPanel();
form.setBodyBorder(false);
form.setHeaderVisible(false);
form.mask("lalala");

TextField test1 = new TextField();
test1.setFieldLabel("Field1");
TextField test2 = new TextField();
test2.setFieldLabel("Field2");

form.add(test1);
form.add(test2);

container.add(form);
viewport.add(container);
RootPanel.get().add(viewport);
}
}

Do you get the same result when using my testcase?

Greets,
oxy