Main window header/footer problem

Hello, I want to know it is possible to create scroll able main window with footer (footer should be all time be on the window bottom, but should not be all time visible).

Panel rootLayout = new Panel();

		VerticalLayout content = (VerticalLayout) rootLayout.getContent();

		VerticalLayout layout = new VerticalLayout();

		VerticalLayout headerLayout = new VBHeaderLayout();
		VerticalLayout footerLayout = new VBFooterLayout();
		VerticalLayout loginLayout = new LoginLayout();

		VerticalLayout contentLayout = new VerticalLayout();



		layout.setComponentAlignment(headerLayout, Alignment.TOP_CENTER);
		layout.setComponentAlignment(footerLayout, Alignment.BOTTOM_CENTER);


Using this code I able only to locate footer layout bottom inside panel content layout, not main window. I found only one opportunity to locate footer on the main window bottom, is set full size for panel content, but if panel content is set size full, this panel will not be longer scroll able. Any suggest how it is possible to do?

add back the content.setSizeFull(); that you have commented away, then change contentLayout into a panel and set size full for that panel. You might also want to do layout.setExpandRatio(contentLayout, 1); to the main part take as much space as possible, and make the header and footer to just so small as they need to be.

You are right, if I will set size full for panel content layout, this will solve my problem, until new component with will be added into panel will be same or less than panel height, if height of new component will be greater, should be shown scroll bar, but this never happen because we set panel layout full size.