List of usage examples for com.vaadin.ui AbstractLayout setWidth
@Override public void setWidth(String width)
From source file:edu.nps.moves.mmowgli.components.GhostVerticalLayoutWrapper.java
License:Open Source License
public void ghost_setContent(AbstractLayout lay) { middle.addComponent(lay);/*from w w w . j av a 2 s .co m*/ // won't work? lay.addStyleName("m-ghostBoxContent"); lay.setWidth(CONTENT_WIDTH); }
From source file:org.semanticsoft.vaaclipse.presentation.renderers.TrimBarRenderer.java
License:Open Source License
@Override public void createWidget(MUIElement element, MElementContainer<MUIElement> parent) { if (!(element instanceof MTrimBar)) { return;/*from ww w . j a va 2s . c o m*/ } MTrimBar mTrimBar = (MTrimBar) element; int orientation = mTrimBar.getSide().getValue(); AbstractLayout trimBar = null; if (orientation == SideValue.BOTTOM_VALUE) { trimBar = new CssLayout(); trimBar.addStyleName("horizontaltrimbar"); } else if (orientation == SideValue.TOP_VALUE) { trimBar = new CssLayout(); trimBar.addStyleName("toptrimbar"); } else if (orientation == SideValue.LEFT_VALUE || orientation == SideValue.RIGHT_VALUE) { trimBar = new VerticalLayout(); trimBar.addStyleName("verticaltrimbar"); } trimBar.setSizeUndefined(); if (orientation == SideValue.BOTTOM_VALUE || orientation == SideValue.TOP_VALUE) { trimBar.setWidth("100%"); } element.setWidget(trimBar); }