How can I place few buttons each after another in VerticalLayout?

Hi there, I’m working on simple sidebar, I want to place some buttons each after another. If I don’t define height of my layout it works fine, but when I set it to 100% (with is need for sidebar) items share the space equally, how can I disable that? I need this effect:

you can create another VerticalLayout that has undefined height inside your sidebar.


layout.setHeight("100%"); /*your sidebar*/

VerticalLayout innerlayout = new VerticalLayout();
innerLayout.setHeightUndefined(); /*optional*/
innerlayout.addComponent(new Button("A"));
innerlayout.addComponent(new Button("B"));