Subwindow and Tabsheet

I created a subwindow. A tabsheet added.
Unfortunately I get an edge? Why is that?

public class ClassName extends VerticalLayout implements
        TabSheet.SelectedTabChangeListener {

    private TabSheet t;

    public ClassName() {
          t = new TabSheet();
          t.setSizeFull(); //  does not work ?


Thanks for the help!

By default a sub-window contains a VerticalLayout that has margins enabled, and you add your ClassName class to this VerticalLayout. In your case a better approach is to set ClassName as the content of the sub-window and it replaces the VerticalLayout with margins.


mySubWindow.setContent(new ClassName());

instead of

mySubWindow.addComponent(new ClassName());



Thank you! It works perfectly -_-

By the way, same is true of Window as well as sub-window. Both have a Layout installed by default. If you want the TabSheet to fill the window, replace the layout with the TabSheet, otherwise add the TabSheet.