assertEquals(0, fillData.getMarginBottom());
assertEquals(0, fillData.getMarginLeft());
}
public void test_marginProperties_get() throws Exception {
LayoutContainerInfo container =
parseJavaInfo(
"public class Test extends LayoutContainer {",
" public Test() {",
" setLayout(new FillLayout());",
" {",
" Button button = new Button();",
" add(button, new FillData(1, 2, 3, 4));",
" }",
" }",
"}");
container.refresh();
WidgetInfo button = container.getWidgets().get(0);
FillDataInfo fillData = FillLayoutInfo.getFillData(button);
// check margins
assertSame(Property.UNKNOWN_VALUE, fillData.getPropertyByTitle("margin-all").getValue());
assertEquals(1, fillData.getPropertyByTitle("margin-top").getValue());
assertEquals(2, fillData.getPropertyByTitle("margin-right").getValue());