|
|||||||||
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.smartgwt.client.widgets.BaseWidget
com.smartgwt.client.widgets.Canvas
com.smartgwt.client.widgets.tile.TileLayout
public class TileLayout
Lays out a series of components, calls "tiles", in a grid with multiple tiles per row.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class com.google.gwt.user.client.ui.UIObject |
---|
com.google.gwt.user.client.ui.UIObject.DebugIdImpl, com.google.gwt.user.client.ui.UIObject.DebugIdImplEnabled |
Field Summary |
---|
Fields inherited from class com.smartgwt.client.widgets.BaseWidget |
---|
config, configOnly, id, isElementSet |
Fields inherited from class com.google.gwt.user.client.ui.UIObject |
---|
DEBUG_ID_PREFIX |
Constructor Summary | |
---|---|
TileLayout()
|
|
TileLayout(com.google.gwt.core.client.JavaScriptObject jsObj)
|
Method Summary | |
---|---|
void |
addTile(Canvas tile)
Add a tile to the layout, dynamically. |
void |
addTile(Canvas tile,
int index)
Add a tile to the layout, dynamically. |
protected com.google.gwt.core.client.JavaScriptObject |
create()
|
java.lang.Boolean |
getAnimateTileChange()
If set, tiles animate to their new positions when a tile is added, removed, or reordered via drag and drop. |
java.lang.Boolean |
getAutoWrapLines()
When LayoutPolicy is "flow", should we automatically start a new line when there's
not enough room to fit the next tile on the same line?
|
DragDataAction |
getDragDataAction()
Indicates what to do with data dragged into another DataBoundComponent. |
java.lang.Boolean |
getExpandMargins()
With LayoutPolicy :"fit", should margins be expanded so that tiles fill the
available space in the TileLayout on the breadth axis? |
int |
getLayoutMargin()
A margin left around the outside of all tiles. |
static TileLayout |
getOrCreateRef(com.google.gwt.core.client.JavaScriptObject jsObj)
|
Orientation |
getOrientation()
Direction of tiling. |
Overflow |
getOverflow()
Normal Overflow settings can be used on TileLayouts, for example, an
overflow:auto TileLayout will scroll if members exceed its specified size, whereas an
overflow:visible TileLayout will grow to accomodate members. |
java.lang.Boolean |
getPaddingAsLayoutMargin()
If this widget has padding specified (as padding or in the
CSS style applied to this layout), should it show up as space outside the members,
similar to layoutMargin?
|
Canvas |
getTile(int index)
Retrieve a tile by index. |
java.lang.Integer |
getTileHeight()
Height of each tile in pixels. |
java.lang.Integer |
getTileHMargin()
Horizontal margin in between tiles. |
int |
getTileMargin()
Margin in between tiles. |
int |
getTileSize()
Size of each tile in pixels. |
java.lang.Integer |
getTilesPerLine()
Number of tiles to show in each line. |
java.lang.Integer |
getTileVMargin()
Vertical margin in between tiles. |
java.lang.Integer |
getTileWidth()
Width of each tile in pixels. |
void |
layoutTiles()
Forces layout out the tiles |
boolean |
removeTile(Canvas tile)
Remove a tile from the layout. |
boolean |
removeTile(int tileIndex)
Remove a tile from the layout. |
boolean |
removeTile(java.lang.String tileID)
Remove a tile from the layout. |
void |
setAnimateTileChange(java.lang.Boolean animateTileChange)
If set, tiles animate to their new positions when a tile is added, removed, or reordered via drag and drop. |
void |
setAutoWrapLines(java.lang.Boolean autoWrapLines)
When LayoutPolicy is "flow", should we automatically start a new line when there's
not enough room to fit the next tile on the same line?
|
void |
setDragDataAction(DragDataAction dragDataAction)
Indicates what to do with data dragged into another DataBoundComponent. |
void |
setExpandMargins(java.lang.Boolean expandMargins)
With LayoutPolicy :"fit", should margins be expanded so that tiles fill the
available space in the TileLayout on the breadth axis? |
void |
setLayoutMargin(int layoutMargin)
A margin left around the outside of all tiles. |
void |
setLayoutPolicy(TileLayoutPolicy layoutPolicy)
Policy for laying out tiles. |
void |
setOrientation(Orientation orientation)
Direction of tiling. |
void |
setOverflow(Overflow overflow)
Normal Overflow settings can be used on TileLayouts, for example, an
overflow:auto TileLayout will scroll if members exceed its specified size, whereas an
overflow:visible TileLayout will grow to accomodate members. |
void |
setPaddingAsLayoutMargin(java.lang.Boolean paddingAsLayoutMargin)
If this widget has padding specified (as padding or in the
CSS style applied to this layout), should it show up as space outside the members,
similar to layoutMargin?
|
void |
setTileHeight(java.lang.Integer tileHeight)
Height of each tile in pixels. |
void |
setTileHMargin(java.lang.Integer tileHMargin)
Horizontal margin in between tiles. |
void |
setTileMargin(int tileMargin)
Margin in between tiles. |
void |
setTiles(Canvas... tiles)
List of tiles to lay out. |
void |
setTileSize(int tileSize)
Size of each tile in pixels. |
void |
setTilesPerLine(java.lang.Integer tilesPerLine)
Number of tiles to show in each line. |
void |
setTileVMargin(java.lang.Integer tileVMargin)
Vertical margin in between tiles. |
void |
setTileWidth(java.lang.Integer tileWidth)
Width of each tile in pixels. |
Methods inherited from class com.google.gwt.user.client.ui.Widget |
---|
doAttachChildren, doDetachChildren, getParent, isAttached, onAttach, onBrowserEvent, onDetach, onLoad, onUnload, removeFromParent |
Methods inherited from class com.google.gwt.user.client.ui.UIObject |
---|
addStyleDependentName, ensureDebugId, ensureDebugId, ensureDebugId, getStyleElement, getStyleName, getStylePrimaryName, getStylePrimaryName, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, setElement, setPixelSize, setSize, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setVisible, sinkEvents, unsinkEvents |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Constructor Detail |
---|
public TileLayout()
public TileLayout(com.google.gwt.core.client.JavaScriptObject jsObj)
Method Detail |
---|
public static TileLayout getOrCreateRef(com.google.gwt.core.client.JavaScriptObject jsObj)
protected com.google.gwt.core.client.JavaScriptObject create()
create
in class Canvas
public void setTileSize(int tileSize) throws java.lang.IllegalStateException
LayoutPolicy
, tileSize
may be taken as a maximum, minimum or exact size of tiles, or may be irrelevant.
Width and height may be separately set via tileHeight
and tileWidth
.
sets the height and width of tiles
tileSize
- size. Default value is 50
java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getTileSize()
LayoutPolicy
, tileSize
may be taken as a maximum, minimum or exact size of tiles, or may be irrelevant.
Width and height may be separately set via tileHeight
and tileWidth
.
public void setTileWidth(java.lang.Integer tileWidth) throws java.lang.IllegalStateException
tileSize
.
sets the width of tiles
tileWidth
- width. Default value is null
java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Integer getTileWidth()
tileSize
.
public void setTileHeight(java.lang.Integer tileHeight) throws java.lang.IllegalStateException
tileSize
.
sets the height of tiles
tileHeight
- height. Default value is null
java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Integer getTileHeight()
tileSize
.
public void setTileMargin(int tileMargin) throws java.lang.IllegalStateException
tileHMargin
and
tileVMargin
.
sets the width of tiles
tileMargin
- margin. Default value is 10
java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getTileMargin()
tileHMargin
and
tileVMargin
.
public void setTileHMargin(java.lang.Integer tileHMargin) throws java.lang.IllegalStateException
tileMargin
.
sets the width of tiles
tileHMargin
- width. Default value is null
java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Integer getTileHMargin()
tileMargin
.
public void setTileVMargin(java.lang.Integer tileVMargin) throws java.lang.IllegalStateException
tileMargin
.
sets the width of tiles
tileVMargin
- width. Default value is null
java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Integer getTileVMargin()
tileMargin
.
public void setLayoutMargin(int layoutMargin) throws java.lang.IllegalStateException
layoutMargin
- layoutMargin Default value is 5
java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getLayoutMargin()
public void setPaddingAsLayoutMargin(java.lang.Boolean paddingAsLayoutMargin)
padding
or in the
CSS style applied to this layout), should it show up as space outside the members,
similar to layoutMargin?
If this setting is false, padding will not affect member positioning (as CSS padding normally does not affect absolutely positioned children). Leaving this setting true allows a designer to more effectively control layout purely from CSS.
Note that layoutMargin
if specified, takes precidence over this value.
Note : This is an advanced setting
paddingAsLayoutMargin
- paddingAsLayoutMargin Default value is truepublic java.lang.Boolean getPaddingAsLayoutMargin()
padding
or in the
CSS style applied to this layout), should it show up as space outside the members,
similar to layoutMargin?
If this setting is false, padding will not affect member positioning (as CSS padding normally does not affect absolutely positioned children). Leaving this setting true allows a designer to more effectively control layout purely from CSS.
Note that layoutMargin
if specified, takes precidence over this value.
public void setAnimateTileChange(java.lang.Boolean animateTileChange)
Note : This is an advanced setting
animateTileChange
- animateTileChange Default value is truepublic java.lang.Boolean getAnimateTileChange()
public void setOrientation(Orientation orientation) throws java.lang.IllegalStateException
com.smartgwt.client..TileLayoutPolicy
.
orientation
- orientation Default value is "horizontal"
java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic Orientation getOrientation()
com.smartgwt.client..TileLayoutPolicy
.
public void setTilesPerLine(java.lang.Integer tilesPerLine) throws java.lang.IllegalStateException
tileSize
for some layout
modes. See com.smartgwt.client..TileLayoutPolicy
.
tilesPerLine
- tilesPerLine Default value is null
java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Integer getTilesPerLine()
tileSize
for some layout
modes. See com.smartgwt.client..TileLayoutPolicy
.
public void setOverflow(Overflow overflow) throws java.lang.IllegalStateException
Overflow
settings can be used on TileLayouts, for example, an
overflow:auto TileLayout will scroll if members exceed its specified size, whereas an
overflow:visible TileLayout will grow to accomodate members.
setOverflow
in class Canvas
overflow
- overflow Default value is "visible"
java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic Overflow getOverflow()
Overflow
settings can be used on TileLayouts, for example, an
overflow:auto TileLayout will scroll if members exceed its specified size, whereas an
overflow:visible TileLayout will grow to accomodate members.
getOverflow
in class Canvas
public void setExpandMargins(java.lang.Boolean expandMargins) throws java.lang.IllegalStateException
LayoutPolicy
:"fit", should margins be expanded so that tiles fill the
available space in the TileLayout on the breadth axis?
expandMargins
- expandMargins Default value is true
java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getExpandMargins()
LayoutPolicy
:"fit", should margins be expanded so that tiles fill the
available space in the TileLayout on the breadth axis?
public void setAutoWrapLines(java.lang.Boolean autoWrapLines) throws java.lang.IllegalStateException
LayoutPolicy
is "flow", should we automatically start a new line when there's
not enough room to fit the next tile on the same line?
If set to false, a new line will only be started if a tile specifies tile.startLine or tile.endLine.
autoWrapLines
- autoWrapLines Default value is true
java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getAutoWrapLines()
LayoutPolicy
is "flow", should we automatically start a new line when there's
not enough room to fit the next tile on the same line?
If set to false, a new line will only be started if a tile specifies tile.startLine or tile.endLine.
public void setDragDataAction(DragDataAction dragDataAction)
dragDataAction
- dragDataAction Default value is Canvas.MOVEpublic DragDataAction getDragDataAction()
public Canvas getTile(int index)
The TileLayout consistently uses this method to access tiles, in order to allow subclasses to create tiles on demand.
index
- index of the tile
public void addTile(Canvas tile)
tile
- new tile to addpublic void addTile(Canvas tile, int index)
tile
- new tile to addindex
- position where the tile should be added. Defaults to adding the tile at the end.public void setTiles(Canvas... tiles) throws java.lang.IllegalStateException
tiles
- tiles Default value is null
java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic void setLayoutPolicy(TileLayoutPolicy layoutPolicy) throws java.lang.IllegalStateException
TileLayoutPolicy
for options.
layoutPolicy
- layoutPolicy Default value is ""
java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic boolean removeTile(int tileIndex)
tileIndex
- index or String ID of the tile
public boolean removeTile(java.lang.String tileID)
tileID
- index or String ID of the tile
public boolean removeTile(Canvas tile)
tile
- index or String ID of the tile
public void layoutTiles()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |