Hi,
In my code I try to insert full sized TabSheet component into a scrollable component (Panel for example).
Unfortunately, if I add ValoTheme.TABSHEET_PADDED_TABBAR style to my tabsheet, it causes undesirable scrollbar.
@Theme(ValoTheme.THEME_NAME)
public class MyVaadinUI extends UI {
@Override
protected void init( VaadinRequest request ) {
final VerticalLayout content = new VerticalLayout();
content.setMargin( true );
content.setDefaultComponentAlignment( Alignment.TOP_CENTER );
final TabSheet tabSheet = new TabSheet();
tabSheet.addTab( new Label(), "Tab-1" );
tabSheet.addTab( new Label(), "Tab-2" );
tabSheet.addStyleName( ValoTheme.TABSHEET_PADDED_TABBAR );
tabSheet.addStyleName( ValoTheme.TABSHEET_FRAMED );
tabSheet.setSizeFull();
final Panel panel = new Panel( tabSheet );
panel.setWidth( "400px" );
panel.setHeight( "300px" );
panel.setCaption( "Scrollable component" );
content.addComponent( panel );
setContent( content );
}
@WebServlet(value = "/*", asyncSupported = true)
@VaadinServletConfiguration(productionMode = false, ui = MyVaadinUI.class)
public static class Servlet extends VaadinServlet {
}
}
Thanks,
Dmitry