|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.google.gwt.user.client.ui.UIObject
com.google.gwt.user.client.ui.Widget
com.sencha.gxt.widget.core.client.Component
com.sencha.gxt.widget.core.client.container.Container
com.sencha.gxt.widget.core.client.container.ResizeContainer
com.sencha.gxt.widget.core.client.container.InsertResizeContainer
com.sencha.gxt.widget.core.client.container.CssFloatLayoutContainer
public class CssFloatLayoutContainer
A layout container that uses the CSS float style to enable widgets to float around other widgets.
Code Snippet:
CssFloatLayoutContainer c = new CssFloatLayoutContainer();
HTML rectangle = new HTML("I'm a Red
Rectangle");
Label text = new Label("This text will flow around the Red Rectangle because that's the way things work in CssFloatLayoutContainer. You may need to resize the browser window to see the effect.");
c.add(rectangle, new CssFloatData(100));
c.add(text);
rectangle.getElement().getStyle().setBackgroundColor("red");
text.getElement().getStyle().setFloat(Float.NONE);
text.getElement().getStyle().setDisplay(Display.INLINE);
Viewport v = new Viewport();
v.add(c);
RootPanel.get().add(v);
| Nested Class Summary | |
|---|---|
static class |
CssFloatLayoutContainer.CssFloatData
Specifies widget layout parameters that control the size of the widget. |
static interface |
CssFloatLayoutContainer.CssFloatLayoutAppearance
|
| Nested classes/interfaces inherited from class com.google.gwt.user.client.ui.UIObject |
|---|
UIObject.DebugIdImpl, UIObject.DebugIdImplEnabled |
| Nested classes/interfaces inherited from interface com.google.gwt.user.client.ui.InsertPanel |
|---|
InsertPanel.ForIsWidget |
| Nested classes/interfaces inherited from interface com.google.gwt.user.client.ui.HasWidgets |
|---|
HasWidgets.ForIsWidget |
| Field Summary |
|---|
| Fields inherited from class com.google.gwt.user.client.ui.UIObject |
|---|
DEBUG_ID_PREFIX |
| Constructor Summary | |
|---|---|
CssFloatLayoutContainer()
Creates a CSS float layout container with the default appearance. |
|
CssFloatLayoutContainer(CssFloatLayoutContainer.CssFloatLayoutAppearance appearance)
Creates a CSS float layout container with the specified appearance. |
|
| Method Summary | |
|---|---|
void |
add(IsWidget child,
CssFloatLayoutContainer.CssFloatData layoutData)
Adds a widget to the CSS float layout container with the specified layout parameters. |
HandlerRegistration |
addScrollHandler(ScrollHandler handler)
|
ScrollSupport.ScrollMode |
getScrollMode()
Returns the scroll mode from the container's ScrollSupport
instance. |
ScrollSupport |
getScrollSupport()
Returns the scroll support instance. |
Style.Float |
getStyleFloat()
Returns the value of the CSS float property. |
void |
insert(IsWidget w,
int beforeIndex,
CssFloatLayoutContainer.CssFloatData layoutData)
Inserts the widget at the specified index in the CSS float layout container. |
boolean |
isAdjustForScroll()
Returns true if adjust for scroll is enabled. |
void |
setAdjustForScroll(boolean adjustForScroll)
True to adjust the container width calculations to account for the scroll bar (defaults to false). |
void |
setScrollMode(ScrollSupport.ScrollMode scrollMode)
Sets the scroll mode on the container's ScrollSupport
instance. |
void |
setScrollSupport(ScrollSupport support)
Sets the scroll support. |
void |
setStyleFloat(Style.Float styleFloat)
Sets the value of the CSS float property. |
| Methods inherited from class com.sencha.gxt.widget.core.client.container.InsertResizeContainer |
|---|
insert, insert |
| Methods inherited from class com.sencha.gxt.widget.core.client.container.ResizeContainer |
|---|
forceLayout, isLayoutRunning, isOrWasLayoutRunning, onResize |
| Methods inherited from class com.sencha.gxt.widget.core.client.container.Container |
|---|
add, add, addAddHandler, addBeforeAddHandler, addBeforeRemoveHandler, addContainerHandler, addRemoveHandler, clear, disable, enable, findWidget, getItemByItemId, getWidget, getWidgetCount, getWidgetIndex, getWidgetIndex, iterator, remove, remove, remove |
| Methods inherited from class com.google.gwt.user.client.ui.Widget |
|---|
addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, getLayoutData, getParent, isAttached, removeFromParent, setLayoutData, sinkEvents |
| Methods inherited from class com.google.gwt.user.client.ui.UIObject |
|---|
addStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getOffsetHeight, getOffsetWidth, getStyleName, getStylePrimaryName, getTitle, isVisible, removeStyleDependentName, removeStyleName, setStyleDependentName, setStyleName, setStyleName, setStylePrimaryName, setTitle, setVisible, sinkBitlessEvent, toString, unsinkEvents |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface com.google.gwt.user.client.ui.InsertPanel.ForIsWidget |
|---|
add |
| Methods inherited from interface com.google.gwt.user.client.ui.InsertPanel |
|---|
add |
| Methods inherited from interface com.google.gwt.user.client.ui.IndexedPanel.ForIsWidget |
|---|
getWidgetIndex |
| Methods inherited from interface com.google.gwt.user.client.ui.IndexedPanel |
|---|
getWidget, getWidgetCount, getWidgetIndex, remove |
| Constructor Detail |
|---|
public CssFloatLayoutContainer()
public CssFloatLayoutContainer(CssFloatLayoutContainer.CssFloatLayoutAppearance appearance)
appearance - the appearance of the CSS float layout container| Method Detail |
|---|
@UiChild(tagname="child")
public void add(IsWidget child,
CssFloatLayoutContainer.CssFloatData layoutData)
child - the widget to add to the layout containerlayoutData - the parameters that describe how to lay out the widgetpublic HandlerRegistration addScrollHandler(ScrollHandler handler)
addScrollHandler in interface HasScrollHandlerspublic ScrollSupport.ScrollMode getScrollMode()
ScrollSupport
instance.
public ScrollSupport getScrollSupport()
HasScrollSupport
getScrollSupport in interface HasScrollSupportpublic Style.Float getStyleFloat()
public void insert(IsWidget w,
int beforeIndex,
CssFloatLayoutContainer.CssFloatData layoutData)
w - the widget to insert in the layout containerbeforeIndex - the insert indexlayoutData - the parameters that describe how to lay out the widgetpublic boolean isAdjustForScroll()
public void setAdjustForScroll(boolean adjustForScroll)
adjustForScroll - the adjust for scroll statepublic void setScrollMode(ScrollSupport.ScrollMode scrollMode)
ScrollSupport
instance. The scroll mode will not be preserved if
setScrollSupport(ScrollSupport) is called after calling this
method.
scrollMode - the scroll modepublic void setScrollSupport(ScrollSupport support)
HasScrollSupport
setScrollSupport in interface HasScrollSupportsupport - the scroll supportpublic void setStyleFloat(Style.Float styleFloat)
styleFloat - the value of the CSS float property
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||