@Override public Component initContent() { HorizontalLayout layout = new HorizontalLayout(); layout.setSpacing(true); layout.setWidth("100%"); layout.addComponent(oidType); layout.addComponent(oidValue); layout.setExpandRatio(oidValue, 1); return layout; }
private Layout createFooter() { HorizontalLayout footer = new HorizontalLayout(); footer.setSpacing(true); footer.setMargin(true); footer.setWidth(100, Unit.PERCENTAGE); footer.addComponent(okayButton); footer.setComponentAlignment(okayButton, Alignment.BOTTOM_RIGHT); return footer; }
private Layout createMainArea(final String description) { HorizontalLayout layout = new HorizontalLayout(); layout.setSpacing(true); layout.setMargin(true); layout.setWidth(100, Unit.PERCENTAGE); Label label = new Label(description, ContentMode.PREFORMATTED); label.setWidth(100, Unit.PERCENTAGE); layout.addComponent(label); return layout; }
horizontalLayout1.setWidth("100%"); horizontalLayout1.setDefaultComponentAlignment(Alignment.TOP_RIGHT); HorizontalLayout horizontalLayout2= new HorizontalLayout();
horizontalLayout.setWidth(100, Unit.PERCENTAGE);
horizontalLayout1.setWidth("100%"); horizontalLayout1.setDefaultComponentAlignment(Alignment.TOP_RIGHT); HorizontalLayout horizontalLayout2= new HorizontalLayout();
horizontalLayout.setWidth(375, Sizeable.Unit.PIXELS); verticalLayout.addComponent(horizontalLayout);
horizontalLayout.setWidth(375, Sizeable.Unit.PIXELS); verticalLayout.addComponent(horizontalLayout);
private Component getLegend(String entity) { HorizontalLayout horizontalLayout = new HorizontalLayout(); horizontalLayout.setSpacing(true); horizontalLayout.addStyleName("summary"); horizontalLayout.addStyleName("global"); Label labelx = new Label(entity); labelx.addStyleName("summary-font-legend"); Image ackdImage = new Image(null, new ThemeResource("img/acknowledged.png")); ackdImage.setWidth(16, Sizeable.Unit.PIXELS); Image unackdImage = new Image(null, new ThemeResource("img/unacknowledged.png")); unackdImage.setWidth(16, Sizeable.Unit.PIXELS); Label dummyLabel = new Label(); dummyLabel.setWidth(32, Sizeable.Unit.PIXELS); horizontalLayout.addComponent(labelx); horizontalLayout.addComponent(ackdImage); horizontalLayout.addComponent(unackdImage); horizontalLayout.addComponent(dummyLabel); horizontalLayout.setComponentAlignment(ackdImage, Alignment.TOP_RIGHT); horizontalLayout.setComponentAlignment(unackdImage, Alignment.TOP_RIGHT); horizontalLayout.setExpandRatio(labelx, 4.0f); horizontalLayout.setExpandRatio(ackdImage, 1.0f); horizontalLayout.setExpandRatio(unackdImage, 1.0f); horizontalLayout.setExpandRatio(dummyLabel, 1.0f); horizontalLayout.setWidth(375, Sizeable.Unit.PIXELS); return horizontalLayout; }
upperLayout.setComponentAlignment(leftButtonGroup, Alignment.TOP_LEFT); upperLayout.setComponentAlignment(rightButtonGroup, Alignment.TOP_RIGHT); upperLayout.setWidth(100, Unit.PERCENTAGE); addComponent(upperLayout);
horizontalLayout.setWidth("100%");
buttonLayout.setMargin(true); buttonLayout.setSpacing(true); buttonLayout.setWidth("100%"); buttonLayout.addComponent(close); buttonLayout.setComponentAlignment(close, Alignment.BOTTOM_RIGHT);
horizontalLayout.addComponent(label); horizontalLayout.setWidth(100, Unit.PERCENTAGE);
horizontalLayout.setWidth(100, Unit.PERCENTAGE);
horizontalLayout.setWidth(100, Unit.PERCENTAGE); horizontalLayout.setSpacing(false); horizontalLayout.setPrimaryStyleName("v-caption-surveillance-view");
horizontalLayout.setWidth("100%");