开发者

Resizing a GWT DockLayoutPanel's North/South/East/West components

开发者 https://www.devze.com 2023-01-06 03:02 出处:网络
Does anybody know how to resize a GWT DockLayoutPanel\'s child panels?When I add a directional panel I have to give it a size ie:

Does anybody know how to resize a GWT DockLayoutPanel's child panels? When I add a directional panel I have to give it a size ie:

panel.addSouth(new HTML("south"), 2);

How can I then resize this sou开发者_运维问答th panel after the fact?


You can use the setWidgetSize method like this:

DockLayoutPanel panel = new DockLayoutPanel(Style.Unit.EM);

HTML html = new HTML("south");
panel.addSouth(html, 2);

// change the size of the html widget to 4em
panel.setWidgetSize(html, 4);
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号