code: public UITabGroup attachTo(UIContainer container, boolean displace)
  	{
  		attachedContainer = container;
  		if (activeTab != null)
  			activeTab.setActive(true);
  
  		switch (tabPosition)
  		{
  			case TOP:
  				setPosition(Position.above(this, container, -2));
  				break;
  			case BOTTOM:
  				setPosition(Position.below(this, container, -2));
  				break;
  			case LEFT:
  				setPosition(Position.leftOf(this, container, -2));
  				break;
  			case RIGHT:
  				setPosition(Position.rightOf(this, container, -2));
  				break;
  		}
  
  		for (UIContainer tabContainer : listTabs.values())
  			setupTabContainer(tabContainer);
  
  		calculateTabPosition();
  
  		if (activeTab != null)
  		{
  			UITab tab = activeTab;
  			activeTab = null;
  			setActiveTab(tab);
  		}
  
  		if (displace)
  		{
  			attachedContainer.setPosition(new AttachedContainerPosition(attachedContainer.position()));
  			attachedContainer.setSize(new AttachedContainerSize(attachedContainer.size()));
  		}
  
  		return this;
  	}
docs: Attach this {@link UITabGroup} to a {@link UIContainer}.
  
  @param container the container to attach to.
  @param displace if true, moves and resize the UIContainer to make place for the UITabGroup
  @return this {@link UITab}