com.google.gwt.user.client.ui
Class VerticalPanel

java.lang.Object
  extended bycom.google.gwt.user.client.ui.UIObject
      extended bycom.google.gwt.user.client.ui.Widget
          extended bycom.google.gwt.user.client.ui.Panel
              extended bycom.google.gwt.user.client.ui.ComplexPanel
                  extended bycom.google.gwt.user.client.ui.CellPanel
                      extended bycom.google.gwt.user.client.ui.VerticalPanel
All Implemented Interfaces:
EventListener, HasAlignment, HasHorizontalAlignment, HasVerticalAlignment, HasWidgets

public class VerticalPanel
extends CellPanel
implements HasAlignment

A panel that lays all of its widgets out in a single vertical column.


Nested Class Summary
 
Nested classes inherited from class com.google.gwt.user.client.ui.HasHorizontalAlignment
HasHorizontalAlignment.HorizontalAlignmentConstant
 
Nested classes inherited from class com.google.gwt.user.client.ui.HasVerticalAlignment
HasVerticalAlignment.VerticalAlignmentConstant
 
Field Summary
 
Fields inherited from class java.lang.Object
typeId, typeName
 
Fields inherited from interface com.google.gwt.user.client.ui.HasHorizontalAlignment
ALIGN_CENTER, ALIGN_LEFT, ALIGN_RIGHT
 
Fields inherited from interface com.google.gwt.user.client.ui.HasVerticalAlignment
ALIGN_BOTTOM, ALIGN_MIDDLE, ALIGN_TOP
 
Constructor Summary
VerticalPanel()
          Creates an empty vertical panel.
 
Method Summary
 boolean add(Widget w)
          Adds a new child widget to the panel.
 HasHorizontalAlignment.HorizontalAlignmentConstant getHorizontalAlignment()
          Gets the horizontal alignment.
 HasVerticalAlignment.VerticalAlignmentConstant getVerticalAlignment()
          Gets the vertical alignment.
 boolean insert(Widget w, int beforeIndex)
          Inserts a widget into the panel
 boolean remove(Widget w)
          Removes a widget from the panel.
 void setCellHeight(Widget w, String height)
          Sets the height of the cell associated with the given widget, related to the panel as a whole.
 void setCellHorizontalAlignment(Widget w, HasHorizontalAlignment.HorizontalAlignmentConstant align)
          Sets the horizontal alignment of the given widget within its cell
 void setCellVerticalAlignment(Widget w, HasVerticalAlignment.VerticalAlignmentConstant align)
          Sets the vertical alignment of the given widget within its cell
 void setCellWidth(Widget w, String width)
          Sets the width of the cell associated with the given widget, related to the panel as a whole.
 void setHorizontalAlignment(HasHorizontalAlignment.HorizontalAlignmentConstant align)
          Sets the default horizontal alignment to be used for widgets added to this panel.
 void setVerticalAlignment(HasVerticalAlignment.VerticalAlignmentConstant align)
          Sets the default vertical alignment to be used for widgets added to this panel.
 
Methods inherited from class com.google.gwt.user.client.ui.CellPanel
getSpacing, getTable, setBorderWidth, setSpacing
 
Methods inherited from class com.google.gwt.user.client.ui.ComplexPanel
clear, getWidget, getWidgetCount, getWidgetIndex, iterator
 
Methods inherited from class com.google.gwt.user.client.ui.Panel
adopt, disown, onAttach, onDetach
 
Methods inherited from class com.google.gwt.user.client.ui.Widget
getParent, isAttached, onBrowserEvent, onLoad
 
Methods inherited from class com.google.gwt.user.client.ui.UIObject
addStyleName, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleName, isVisible, isVisible, removeStyleName, setElement, setHeight, setPixelSize, setSize, setStyleName, setStyleName, setVisible, setVisible, setWidth, sinkEvents, toString, unsinkEvents
 
Methods inherited from class java.lang.Object
equals, finalize, hashCode
 

Constructor Detail

VerticalPanel

public VerticalPanel()
Creates an empty vertical panel.

Method Detail

add

public boolean add(Widget w)
Description copied from class: Panel
Adds a new child widget to the panel.

Overrides:
add in class ComplexPanel

getHorizontalAlignment

public HasHorizontalAlignment.HorizontalAlignmentConstant getHorizontalAlignment()
Description copied from interface: HasHorizontalAlignment
Gets the horizontal alignment.

Specified by:
getHorizontalAlignment in interface HasHorizontalAlignment
Returns:
the current horizontal alignment.

getVerticalAlignment

public HasVerticalAlignment.VerticalAlignmentConstant getVerticalAlignment()
Description copied from interface: HasVerticalAlignment
Gets the vertical alignment.

Specified by:
getVerticalAlignment in interface HasVerticalAlignment
Returns:
the current vertical alignment.

insert

public boolean insert(Widget w,
                      int beforeIndex)
Description copied from class: ComplexPanel
Inserts a widget into the panel

Overrides:
insert in class ComplexPanel
Parameters:
w - the widget to be inserted
beforeIndex - the index before which it will be inserted
Returns:
true on success (some panels place restrictions on how children may be added or inserted)

remove

public boolean remove(Widget w)
Description copied from class: Panel
Removes a widget from the panel.

Overrides:
remove in class ComplexPanel

setHorizontalAlignment

public void setHorizontalAlignment(HasHorizontalAlignment.HorizontalAlignmentConstant align)
Sets the default horizontal alignment to be used for widgets added to this panel. It only applies to widgets added after this property is set.

Specified by:
setHorizontalAlignment in interface HasHorizontalAlignment
Parameters:
align - the horizontal alignment ( HasHorizontalAlignment.ALIGN_LEFT, HasHorizontalAlignment.ALIGN_CENTER, or HasHorizontalAlignment.ALIGN_RIGHT).
See Also:
HasHorizontalAlignment#setHorizontalAlignment(HorizontalAlignmentConstant)

setVerticalAlignment

public void setVerticalAlignment(HasVerticalAlignment.VerticalAlignmentConstant align)
Sets the default vertical alignment to be used for widgets added to this panel. It only applies to widgets added after this property is set.

Specified by:
setVerticalAlignment in interface HasVerticalAlignment
Parameters:
align - the vertical alignment ( HasVerticalAlignment.ALIGN_TOP, HasVerticalAlignment.ALIGN_MIDDLE, or HasVerticalAlignment.ALIGN_BOTTOM).
See Also:
HasVerticalAlignment#setVerticalAlignment(VerticalAlignmentConstant)

setCellHorizontalAlignment

public void setCellHorizontalAlignment(Widget w,
                                       HasHorizontalAlignment.HorizontalAlignmentConstant align)
Description copied from class: CellPanel
Sets the horizontal alignment of the given widget within its cell

Specified by:
setCellHorizontalAlignment in class CellPanel
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)
Description copied from class: CellPanel
Sets the vertical alignment of the given widget within its cell

Specified by:
setCellVerticalAlignment in class CellPanel
Parameters:
w - the widget whose vertical alignment is to be set
align - the widget's vertical alignment, as defined in HasVerticalAlignment.

setCellHeight

public void setCellHeight(Widget w,
                          String height)
Description copied from class: CellPanel
Sets the height of the cell associated with the given widget, related to the panel as a whole.

Specified by:
setCellHeight in class CellPanel
Parameters:
w - the widget whose cell height is to be set
height - the cell's height, in CSS units

setCellWidth

public void setCellWidth(Widget w,
                         String width)
Description copied from class: CellPanel
Sets the width of the cell associated with the given widget, related to the panel as a whole.

Specified by:
setCellWidth in class CellPanel
Parameters:
w - the widget whose cell width is to be set
width - the cell's width, in CSS units


This javadoc distribution was not produced by Google. The official documentation is here.