public class RootLayoutPanel extends LayoutPanel
LayoutPanel that always attaches itself
 to the document body (i.e. RootPanel.get()).
 
 
 This panel automatically calls RequiresResize.onResize() on itself
 when initially created, and whenever the window is resized.
 
NOTE: This widget will only work in standards mode, which requires that the HTML page in which it is run have an explicit <!DOCTYPE> declaration.
public class LayoutPanelExample implements EntryPoint {
  public void onModuleLoad() {
    // Attach two child widgets to a LayoutPanel, laying them out horizontally,
    // splitting at 50%.
    Widget childOne = new HTML("left"), childTwo = new HTML("right");
    LayoutPanel p = new LayoutPanel();
    p.add(childOne);
    p.add(childTwo);
    p.setWidgetLeftWidth(childOne, 0, PCT, 50, PCT);
    p.setWidgetRightWidth(childTwo, 0, PCT, 50, PCT);
    // Attach the LayoutPanel to the RootLayoutPanel. The latter will listen for
    // resize events on the window to ensure that its children are informed of
    // possible size changes.
    RootLayoutPanel rp = RootLayoutPanel.get();
    rp.add(p);
  }
}
UIObject.DebugIdImpl, UIObject.DebugIdImplEnabledIndexedPanel.ForIsWidgetHasWidgets.ForIsWidgeteventsToSinkDEBUG_ID_PREFIX, MISSING_ELEMENT_ERROR, SETELEMENT_TWICE_ERROR| Modifier and Type | Method and Description | 
|---|---|
| static RootLayoutPanel | get()Gets the singleton instance of RootLayoutPanel. | 
| protected void | onLoad()This method is called immediately after a widget becomes attached to the
 browser's document. | 
add, animate, animate, forceLayout, getLayout, getWidgetContainerElement, insert, onAttach, onDetach, onResize, remove, setWidgetBottomHeight, setWidgetBottomHeight, setWidgetHorizontalPosition, setWidgetLeftRight, setWidgetLeftRight, setWidgetLeftWidth, setWidgetLeftWidth, setWidgetRightWidth, setWidgetRightWidth, setWidgetTopBottom, setWidgetTopBottom, setWidgetTopHeight, setWidgetTopHeight, setWidgetVerticalPosition, setWidgetVisibleadd, add, adjustIndex, checkIndexBoundsForAccess, checkIndexBoundsForInsertion, doLogicalClear, getChildren, getWidget, getWidgetCount, getWidgetIndex, getWidgetIndex, insert, insert, iterator, removeadd, adopt, clear, doAttachChildren, doDetachChildren, orphan, removeaddAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, ensureHandlers, fireEvent, getHandlerCount, getHandlerManager, getLayoutData, getParent, isAttached, isOrWasAttached, onBrowserEvent, onUnload, removeFromParent, replaceElement, setLayoutData, setParent, sinkEvents, unsinkEventsaddStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, resolvePotentialElement, setElement, setElement, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, sinkBitlessEvent, toStringpublic static RootLayoutPanel get()
RootPanel.get().
 
 
 Note that, unlike RootPanel.get(String), this class provides no way
 to get an instance for any element on the page other than the document
 body. This is because we know of no way to get resize events for anything
 but the window.