com.alkacon.geranium.client.ui
public class FloatDecoratedPanel extends com.google.gwt.user.client.ui.Composite implements I_Truncable
It contains two panels, the "primary" (or main) panel and the "float" panel, to which widgets can be added. The float panel is styled so as to float left of the primary panel, and the primary panel's left margin is set to the width of the float panel. If the widget starts out as hidden, the float panel width can not be measured, so you have to call the updateLayout method manually when the widget becomes visible.
| Constructor and Description |
|---|
FloatDecoratedPanel()
Creates a new instance of the widget.
|
| Modifier and Type | Method and Description |
|---|---|
void |
add(com.google.gwt.user.client.ui.Widget widget)
Adds a widget to the main panel.
|
void |
addToFloat(com.google.gwt.user.client.ui.Widget widget)
Adds a widget to the float panel.
|
void |
addToFrontOfFloat(com.google.gwt.user.client.ui.Widget widget)
Adds a widget to the front of the float panel.
|
com.google.gwt.user.client.ui.Widget |
getWidget(int index)
Returns the widget at the given position.
|
protected void |
onLoad()
Automatically calls the updateLayout method after insertion into the DOM.
|
void |
truncate(java.lang.String textMetricsPrefix,
int widgetWidth)
Truncates long text and sets the original text to the title attribute.
|
void |
updateLayout()
Sets the left margin of the main panel to the width of the float panel.
|
claimElement, getWidget, initializeClaimedElement, initWidget, isAttached, onAttach, onBrowserEvent, onDetach, render, render, resolvePotentialElement, setWidgetaddAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, doAttachChildren, doDetachChildren, fireEvent, getHandlerCount, getLayoutData, getParent, isOrWasAttached, onUnload, removeFromParent, setLayoutData, sinkEvents, unsinkEventsaddStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, setElement, setElement, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, sinkBitlessEvent, toStringpublic FloatDecoratedPanel()
public void add(com.google.gwt.user.client.ui.Widget widget)
widget - the widget to addpublic void addToFloat(com.google.gwt.user.client.ui.Widget widget)
widget - the widget to addpublic void addToFrontOfFloat(com.google.gwt.user.client.ui.Widget widget)
widget - the widget to addpublic com.google.gwt.user.client.ui.Widget getWidget(int index)
index - the positionpublic void truncate(java.lang.String textMetricsPrefix,
int widgetWidth)
I_Truncabletruncate in interface I_TruncabletextMetricsPrefix - the key identifying the text metrics to usewidgetWidth - the width to use in pixelsI_Truncable.truncate(java.lang.String, int)public void updateLayout()
protected void onLoad()
onLoad in class com.google.gwt.user.client.ui.WidgetWidget.onLoad()