List of usage examples for com.vaadin.ui VerticalLayout addComponents
@Override public void addComponents(Component... components)
From source file:de.metas.procurement.webui.ui.view.WeeklyDetailedReportingView.java
License:Open Source License
public WeeklyDetailedReportingView() { super();//from ww w . jav a2 s . c o m addStyleName(STYLE); // // Content { productButtons = new BeansVerticalComponentGroup<ProductQtyReport>() { @Override protected Component createItemComponent(final BeanItem<ProductQtyReport> item) { final ProductItemButton itemComp = new ProductItemButton(); itemComp.setItem(item); return itemComp; } }; final VerticalLayout content = new VerticalLayout(); content.addComponents(productButtons); setContent(content); } // // Toolbar { this.toolbar = new Toolbar(); toolbar.addComponents(createTrendButton(Trend.UP), createTrendButton(Trend.DOWN), createTrendButton(Trend.EVEN), createTrendButton(Trend.ZERO)); setToolbar(toolbar); } }
From source file:org.apache.tamaya.ui.views.AbstractTextInfoProvider.java
License:Apache License
@Override public void addSystemInfo(Accordion systemInfoPanel) { VerticalLayout layout = new VerticalLayout(); textArea = new TextArea("System Info"); textArea.addStyleName(UIConstants.FIXED_FONT); textArea.setValue(getInfo());/*from w w w. j av a2 s . c o m*/ textArea.setRows(20); textArea.setHeight("400px"); textArea.setWidth("100%"); layout.addComponents(textArea); systemInfoPanel.addTab(layout, getCaption()); }
From source file:org.apache.tamaya.ui.views.ConfigView.java
License:Apache License
private Component createRuntimeTab() { VerticalLayout tabLayout = new VerticalLayout(); TextArea runtimeProps = new TextArea(); runtimeProps.setRows(25);//from ww w . j a v a2 s . com StringBuilder b = new StringBuilder(); b.setLength(0); b.append("Available Processors : ").append(Runtime.getRuntime().availableProcessors()).append('\n'); b.append("Free Memory : ").append(Runtime.getRuntime().freeMemory()).append('\n'); b.append("Max Memory : ").append(Runtime.getRuntime().maxMemory()).append('\n'); b.append("Total Memory : ").append(Runtime.getRuntime().totalMemory()).append('\n'); b.append("Default Locale : ").append(Locale.getDefault()).append('\n'); runtimeProps.setValue(b.toString()); runtimeProps.setReadOnly(true); runtimeProps.setHeight("100%"); runtimeProps.setWidth("100%"); tabLayout.addComponents(runtimeProps); tabLayout.setHeight("100%"); tabLayout.setWidth("100%"); return tabLayout; }
From source file:org.apache.tamaya.ui.views.ConfigView.java
License:Apache License
private Component createSysPropsTab() { VerticalLayout tabLayout = new VerticalLayout(); TextArea sysProps = new TextArea(); sysProps.setRows(25);// w w w .j a v a 2s . c o m StringBuilder b = new StringBuilder(); for (Map.Entry<Object, Object> en : new TreeMap<>(System.getProperties()).entrySet()) { b.append(en.getKey()).append("=").append(en.getValue()).append('\n'); } sysProps.setValue(b.toString()); sysProps.setReadOnly(true); sysProps.setHeight("100%"); sysProps.setWidth("100%"); tabLayout.addComponents(sysProps); tabLayout.setHeight("100%"); tabLayout.setWidth("100%"); return tabLayout; }
From source file:org.apache.tamaya.ui.views.ConfigView.java
License:Apache License
private Component createEnvTab() { VerticalLayout tabLayout = new VerticalLayout(); TextArea envProps = new TextArea(); StringBuilder b = new StringBuilder(); envProps.setRows(25);// w ww . ja va2 s. c o m for (Map.Entry<String, String> en : new TreeMap<>(System.getenv()).entrySet()) { b.append(en.getKey()).append("=").append(en.getValue()).append('\n'); } envProps.setValue(b.toString()); envProps.setReadOnly(true); envProps.setHeight("100%"); envProps.setWidth("100%"); tabLayout.addComponents(envProps); tabLayout.setHeight("100%"); tabLayout.setWidth("100%"); return tabLayout; }
From source file:org.rubicone.poc.vpush.uil.sending.SendingUI.java
License:Apache License
private Panel createInstructionsPanel() { Panel instructionsPanel = new Panel("instructions"); VerticalLayout instructionsLayout = new VerticalLayout(); instructionsPanel.setContent(instructionsLayout); Label instructionsLabel = new Label( "open another UI receiving notifications from server using following transport:"); instructionsLayout.addComponent(instructionsLabel); Link websocketsUILink = new Link("websockets", new ExternalResource("./receive-messages-websockets")); websocketsUILink.setIcon(VaadinIcons.CHEVRON_RIGHT_SMALL); websocketsUILink.setTargetName("_blank"); instructionsLayout.addComponent(websocketsUILink); Link websocketsXhrUILink = new Link("websockets + XHR", new ExternalResource("./receive-messages-websocketsxhr")); websocketsXhrUILink.setIcon(VaadinIcons.CHEVRON_RIGHT_SMALL); websocketsXhrUILink.setTargetName("_blank"); instructionsLayout.addComponent(websocketsXhrUILink); Link httpLongPollingUILink = new Link("HTTP long polling", new ExternalResource("./receive-messages-httplongpolling")); httpLongPollingUILink.setIcon(VaadinIcons.CHEVRON_RIGHT_SMALL); httpLongPollingUILink.setTargetName("_blank"); instructionsLayout.addComponent(httpLongPollingUILink); Label noteLabel = new Label( "<i>" + VaadinIcons.INFO_CIRCLE_O.getHtml() + " note: you may open several UIs at the same time to receive push notifications</i>", ContentMode.HTML);/* w ww.jav a 2 s . c o m*/ noteLabel.addStyleName(ValoTheme.LABEL_TINY); instructionsLayout.addComponents(noteLabel); return instructionsPanel; }
From source file:pl.adrian.pieper.biuwaw.NewPartyView.java
private AbstractComponent createPartyForm() { VerticalLayout layout = new VerticalLayout(); layout.addComponents(partNameTF); layout.setMargin(true);//from w w w. j ava 2s . c o m return layout; }