" add(button);",
" }",
" }",
"}");
panel.refresh();
TableLayoutInfo layout = (TableLayoutInfo) panel.getLayout();
WidgetInfo button = panel.getChildrenWidgets().get(0);
TableLayoutDataInfo tableData = TableLayoutInfo.getTableData(button);
// check initial TableLayoutData
{
assertEquals(0, getInt(tableData, "x"));
assertEquals(0, getInt(tableData, "y"));
assertEquals(1, getInt(tableData, "width"));
assertEquals(1, getInt(tableData, "height"));
}
// set horizontal span
layout.command_setCells(button, new Rectangle(0, 0, 2, 1), true);
assertEditor(
"import com.google.gwt.user.client.ui.Button;",
"public class Test extends Panel {",
" public Test() {",
" setLayout(new TableLayout(2));",