本文整理汇总了Java中com.vaadin.ui.VerticalSplitPanel.setWidth方法的典型用法代码示例。如果您正苦于以下问题:Java VerticalSplitPanel.setWidth方法的具体用法?Java VerticalSplitPanel.setWidth怎么用?Java VerticalSplitPanel.setWidth使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.vaadin.ui.VerticalSplitPanel
的用法示例。
在下文中一共展示了VerticalSplitPanel.setWidth方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: buildVerticalSplitPanelMasterDetail
import com.vaadin.ui.VerticalSplitPanel; //导入方法依赖的package包/类
@AutoGenerated
private VerticalSplitPanel buildVerticalSplitPanelMasterDetail() {
// common part: create layout
verticalSplitPanelMasterDetail = new VerticalSplitPanel();
verticalSplitPanelMasterDetail.setImmediate(false);
verticalSplitPanelMasterDetail.setWidth("100.0%");
verticalSplitPanelMasterDetail.setHeight("100.0%");
verticalSplitPanelMasterDetail.setMargin(false);
// topLayout
topLayout = buildTopLayout();
verticalSplitPanelMasterDetail.addComponent(topLayout);
// bottonLayout
bottonLayout = buildBottonLayout();
verticalSplitPanelMasterDetail.addComponent(bottonLayout);
return verticalSplitPanelMasterDetail;
}
示例2: init
import com.vaadin.ui.VerticalSplitPanel; //导入方法依赖的package包/类
@Override
protected void init(VaadinRequest request) {
treeToolEditor = new TreeToolEditor(this);
toolEditor = new ToolEditor(this);
textEditor = new TextEditor(this);
final Panel vLayout = new Panel();
vSplitPanel = new VerticalSplitPanel();
vSplitPanel.setSplitPosition(50, Unit.PERCENTAGE);
vSplitPanel.setImmediate(true);
vSplitPanel.setLocked(false);
vSplitPanel.setWidth("100%");
vLayout.setContent(vSplitPanel);
setContent(vSplitPanel);
VerticalLayout vvLayout = new VerticalLayout();
vvLayout.setSizeFull();
Label title = new Label("<h2><b> Tool Editor</b></h2>", ContentMode.HTML);
vvLayout.addComponent(title);
vvLayout.setComponentAlignment(title, Alignment.TOP_LEFT);
HorizontalSplitPanel hSplitpPanel = new HorizontalSplitPanel();
hSplitpPanel.setSizeFull();
vvLayout.addComponent(hSplitpPanel);
HorizontalLayout buttonPanel = getButtonPanel();
vvLayout.addComponent(buttonPanel);
vvLayout.setComponentAlignment(buttonPanel, Alignment.MIDDLE_CENTER);
vvLayout.setExpandRatio(hSplitpPanel, 5);
vvLayout.setComponentAlignment(hSplitpPanel, Alignment.TOP_LEFT);
vvLayout.setMargin(false);
vvLayout.setSpacing(false);
hSplitpPanel.setFirstComponent(treeToolEditor);
hSplitpPanel.setSecondComponent(toolEditor);
vSplitPanel.setFirstComponent(vvLayout);
vSplitPanel.setSecondComponent(textEditor);
hSplitpPanel.setStyleName("topborder");
}
示例3: InitialLayout
import com.vaadin.ui.VerticalSplitPanel; //导入方法依赖的package包/类
/**
* Im Konstruktor wird das Layout erstellt.
*
* @author Marco Glaser
*
*/
public InitialLayout(){
mainLayout.setSizeFull();
mainLayout.setStyleName("mainLayout");
leftLayout.setSizeFull();
leftLayout.setStyleName("leftContainer");
rightLayout.setSizeFull();
bottomLayout.setSizeFull();
bottomLeftLayout.setSizeFull();
horizontalSplitPanel = new HorizontalSplitPanel();
horizontalSplitPanel.setSplitPosition(30, com.vaadin.terminal.Sizeable.UNITS_PERCENTAGE);
horizontalSplitPanel.setLocked(true);
horizontalSplitPanel.setStyleName("horizontalMain");
verticalSplitPanel = new VerticalSplitPanel();
verticalSplitPanel.setSplitPosition(15, com.vaadin.terminal.Sizeable.UNITS_PERCENTAGE);
verticalSplitPanel.setLocked(true);
verticalSplitPanel.setWidth(90, com.vaadin.terminal.Sizeable.UNITS_PERCENTAGE);
verticalSplitPanel.setHeight(100, com.vaadin.terminal.Sizeable.UNITS_PERCENTAGE);
horizontalSplitPanelRight = new HorizontalSplitPanel();
horizontalSplitPanelRight.setSplitPosition(30, com.vaadin.terminal.Sizeable.UNITS_PERCENTAGE);
horizontalSplitPanelRight.setLocked(true);
horizontalSplitPanelRight.addStyleName("horizontalBottom");
horizontalSplitPanelRight.setHeight(90, com.vaadin.terminal.Sizeable.UNITS_PERCENTAGE);
horizontalSplitPanelRight.setWidth(100, com.vaadin.terminal.Sizeable.UNITS_PERCENTAGE);
leftL = new Label("links");
rightTopL = new Label("rechts Oben");
rightBottomL = new Label("rechts Unten");
leftBottomL = new Label("links Unten");
leftLayout.addComponent(leftL);
rightLayout.addComponent(verticalSplitPanel);
topRightLayout.addComponent(rightTopL);
bottomRightLayout.addComponent(rightBottomL);
// bottomLeftLayout.addComponent(leftBottomL);
bottomLayout.addComponent(horizontalSplitPanelRight);
horizontalSplitPanel.addComponent(leftLayout);
horizontalSplitPanel.addComponent(rightLayout);
verticalSplitPanel.addComponent(topRightLayout);
verticalSplitPanel.addComponent(bottomLayout);
horizontalSplitPanelRight.addComponent(bottomLeftLayout);
horizontalSplitPanelRight.addComponent(bottomRightLayout);
rightLayout.setComponentAlignment(verticalSplitPanel, Alignment.MIDDLE_CENTER);
bottomLayout.setComponentAlignment(horizontalSplitPanelRight, Alignment.MIDDLE_CENTER);
mainLayout.addComponent(horizontalSplitPanel);
}