Basic Design Questions Using Vaadin

Hi,

I was asked to use Vaadin to build a demo website. I just went over the AddressBook example and started to implement mine.

I started my own, part of the codes are here

public void buildMainLayout() {
Window mainWindow = new Window(“Application”);
setMainWindow(mainWindow);

	VerticalLayout baseLayout = new VerticalLayout();

	baseLayout.setSizeFull();
	
	baseLayout.addComponent(createToolbar());
	baseLayout.addComponent(getLoginP());
	baseLayout.addComponent(getRegisterP());
	
	mainWindow.scrollIntoView(baseLayout);
	getMainWindow().setContent(baseLayout);
}

getLoginP() and getRegisterP() will create new Panels and set in there. When I ran it, it was scrollable in each individual Panels, but not as the whole page. Before I set getLoginP() as a Panel, I also tried to get it as a FormLayout instance. It doesn’t make the login part scrollable, but the whole page is not scrollable.

What can I do to set it right?

Thanks,

Hi,

I don’t have a clear picture of your whole layout, but I noticed this:

baseLayout.setSizeFull();

This will make your baseLayout 100% of the window (in both directions), so it will not get scrollbars. You might want to leave remove the setSizeFull() -call.

Best Regards,
Marc