org.cafesip.gwtcomp.client.ui
Class Toolbar

java.lang.Object
  extended by com.google.gwt.user.client.ui.UIObject
      extended by com.google.gwt.user.client.ui.Widget
          extended by com.google.gwt.user.client.ui.Composite
              extended by org.cafesip.gwtcomp.client.ui.Toolbar
All Implemented Interfaces:
HasHandlers, EventListener

public class Toolbar
extends Composite

The toolbar is a simple panel widget that is used to place one or more "tools" into it. A tool can be an image, or any widget. Applications are responsible for setting tool-tips, event listeners, etc. A toolbar can be placed inside a ToolbarPanel.

CSS Style Rules:

Screen-Shots:

Author:
Amit Chatterjee

Nested Class Summary
 
Nested classes/interfaces inherited from class com.google.gwt.user.client.ui.UIObject
UIObject.DebugIdImpl, UIObject.DebugIdImplEnabled
 
Field Summary
 
Fields inherited from class com.google.gwt.user.client.ui.UIObject
DEBUG_ID_PREFIX
 
Constructor Summary
Toolbar()
          A constructor for this class.
 
Method Summary
 void addWidget(Widget w)
          Adds a "tool" widget into the toolbar.
 int getHorizontalSpacing()
          Returns the horizontal spacing in pixels.
 int getVerticalSpacing()
          Returns the vertical spacing (top and bottom).
 void redraw()
          Redraw the toolbar.
 void setHorizontalSpacing(int horizontalSpacing)
          Sets the horizontal spacing between the tools in the toolbar.
 void setVerticalSpacing(int verticalSpacing)
          Sets the vertical spacing.
 
Methods inherited from class com.google.gwt.user.client.ui.Composite
getWidget, initWidget, isAttached, onAttach, onBrowserEvent, onDetach, setWidget
 
Methods inherited from class com.google.gwt.user.client.ui.Widget
addDomHandler, addHandler, delegateEvent, doAttachChildren, doDetachChildren, fireEvent, getHandlerCount, getLayoutData, getParent, isOrWasAttached, onLoad, onUnload, removeFromParent, setLayoutData, sinkEvents
 
Methods inherited from class com.google.gwt.user.client.ui.UIObject
addStyleDependentName, 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, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, toString, unsinkEvents
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Toolbar

public Toolbar()
A constructor for this class.

Method Detail

addWidget

public void addWidget(Widget w)
Adds a "tool" widget into the toolbar.

Parameters:
w - widget to add.

getHorizontalSpacing

public int getHorizontalSpacing()
Returns the horizontal spacing in pixels.

Returns:
Returns the horizontalSpacing.

setHorizontalSpacing

public void setHorizontalSpacing(int horizontalSpacing)
Sets the horizontal spacing between the tools in the toolbar.

Parameters:
horizontalSpacing - The horizontalSpacing to set.

getVerticalSpacing

public int getVerticalSpacing()
Returns the vertical spacing (top and bottom).

Returns:
Returns the verticalSpacing.

setVerticalSpacing

public void setVerticalSpacing(int verticalSpacing)
Sets the vertical spacing.

Parameters:
verticalSpacing - The verticalSpacing to set.

redraw

public void redraw()
Redraw the toolbar. This is needed in some cases when the size of the tools widgets changes.



Copyright © 2010 Cafesip.org. All Rights Reserved.