## com.google.gwt.user.client.ui
Class CellPanel

    java.lang.Object
      com.google.gwt.user.client.ui.UIObject
          com.google.gwt.user.client.ui.Widget
              com.google.gwt.user.client.ui.Panel
                  com.google.gwt.user.client.ui.ComplexPanel
                      com.google.gwt.user.client.ui.CellPanel

All Implemented Interfaces:
  EventListener, HasWidgets, IndexedPanel

Direct Known Subclasses:
  DockPanel, HorizontalPanel, VerticalPanel

    public abstract class CellPanel

extends ComplexPanel

A panel whose child widgets are contained within the cells of a table. Each cell's size may be set independently. Each child widget can take up a subset of its cell and can be aligned within it.

Constructor Summary
`CellPanel()`

Method Summary
`protected Element` `getBody()`
`int` `getSpacing()` Gets the amount of spacing between this panel's cells.
`protected Element` `getTable()`
`void` `setBorderWidth(int width)` Sets the width of the border to be applied to all cells in this panel.
`void` `setCellHeight(Widget w, java.lang.String height)` Sets the height of the cell associated with the given widget, related to the panel as a whole.
`protected void` `setCellHorizontalAlignment(Element td, HasHorizontalAlignment.HorizontalAlignmentConstant align)`
`void` `setCellHorizontalAlignment(Widget w, HasHorizontalAlignment.HorizontalAlignmentConstant align)` Sets the horizontal alignment of the given widget within its cell.
`protected void` `setCellVerticalAlignment(Element td, HasVerticalAlignment.VerticalAlignmentConstant align)`
`void` `setCellVerticalAlignment(Widget w, HasVerticalAlignment.VerticalAlignmentConstant align)` Sets the vertical alignment of the given widget within its cell.
`void` `setCellWidth(Widget w, java.lang.String width)` Sets the width of the cell associated with the given widget, related to the panel as a whole.
`void` `setSpacing(int spacing)` Sets the amount of spacing between this panel's cells.

Methods inherited from class com.google.gwt.user.client.ui.ComplexPanel
`add, adjustIndex, checkIndexBoundsForAccess, checkIndexBoundsForInsertion, getChildren, getWidget, getWidgetCount, getWidgetIndex, insert, insert, iterator, remove, remove`

Methods inherited from class com.google.gwt.user.client.ui.Panel
`add, adopt, adopt, clear, disown, doAttachChildren, doDetachChildren, onLoad, onUnload, orphan`

Methods inherited from class com.google.gwt.user.client.ui.Widget
`getParent, isAttached, onAttach, onBrowserEvent, onDetach, removeFromParent, setElement`

Methods inherited from class com.google.gwt.user.client.ui.UIObject

`addStyleDependentName, addStyleName, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, isVisible, removeStyleDependentName, removeStyleName, setHeight, setPixelSize, setSize, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, sinkEvents, toString, unsinkEvents`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### CellPanel

    public CellPanel()

Method Detail

### getSpacing

    public int getSpacing()

  Gets the amount of spacing between this panel's cells.

  Returns:
    the inter-cell spacing, in pixels

### setBorderWidth

    public void setBorderWidth(int width)

  Sets the width of the border to be applied to all cells in this panel. This is particularly useful when debugging layouts, in that it allows you to see explicitly the cells that contain this panel's children.

  Parameters:
    `width` - the width of the panel's cell borders, in pixels

### setCellHeight

    public void setCellHeight(Widget w,
                              java.lang.String height)

  Sets the height of the cell associated with the given widget, related to the panel as a whole.

  Parameters:
    `w` - the widget whose cell height is to be set
    `height` - the cell's height, in CSS units

### setCellHorizontalAlignment

    public void setCellHorizontalAlignment(Widget w,
                                           HasHorizontalAlignment.HorizontalAlignmentConstant align)

  Sets the horizontal alignment of the given widget within its cell.

  Parameters:
    `w` - the widget whose horizontal alignment is to be set
    `align` - the widget's horizontal alignment, as defined in `HasHorizontalAlignment`.

### setCellVerticalAlignment

    public void setCellVerticalAlignment(Widget w,
                                         HasVerticalAlignment.VerticalAlignmentConstant align)

  Sets the vertical alignment of the given widget within its cell.

  Parameters:
    `w` - the widget whose vertical alignment is to be set
    `align` - the widget's vertical alignment, as defined in `HasVerticalAlignment`.

### setCellWidth

    public void setCellWidth(Widget w,
                             java.lang.String width)

  Sets the width of the cell associated with the given widget, related to the panel as a whole.

  Parameters:
    `w` - the widget whose cell width is to be set
    `width` - the cell's width, in CSS units

### setSpacing

    public void setSpacing(int spacing)

  Sets the amount of spacing between this panel's cells.

  Parameters:
    `spacing` - the inter-cell spacing, in pixels

### getBody

    protected Element getBody()

### getTable

    protected Element getTable()

### setCellHorizontalAlignment

    protected void setCellHorizontalAlignment(Element td,
                                              HasHorizontalAlignment.HorizontalAlignmentConstant align)

### setCellVerticalAlignment

    protected void setCellVerticalAlignment(Element td,
                                            HasVerticalAlignment.VerticalAlignmentConstant align)