org.gnu.gtk
Class ToolBar

java.lang.Object
  |
  +--org.gnu.glib.GObject
        |
        +--org.gnu.gtk.GtkObject
              |
              +--org.gnu.gtk.Widget
                    |
                    +--org.gnu.gtk.Container
                          |
                          +--org.gnu.gtk.ToolBar

public class ToolBar
extends Container

The ToolBar is used to construct a toolbar. It is the container that controls the position of a set of icons that are mouse sensitive.


Constructor Summary
ToolBar()
          Create a new ToolBar
 
Method Summary
 void appendSpace()
          Add a space to the end of the ToolBar.
 void appendWidget(Widget widget, java.lang.String tooltip, java.lang.String helpText)
          Add a widget to the end of the toolbar.
static Type getType()
          Retrieve the runtime type used by the GLib library.
 void insertSpace(int position)
          Insert a space in the ToolBar at the specified location.
 void insertWidget(Widget widget, java.lang.String tooltip, java.lang.String helpText, int index)
          Insert a Widget in the ToolBar at the given position
 void prependSpace()
          Add a space to the beginning of the ToolBar.
 void prependWidget(Widget widget, java.lang.String tooltip, java.lang.String helpText)
          Add a widget to the beginning of the toolbar.
 void removeSpace(int position)
          Remove a space from the ToolBar.
 void setIconSize(IconSize iconSize)
          Sets the size of the stock icons in the ToolBar.
 void setOrientation(Orientation orientation)
          Set whether the ToolBar should appear horizontally or vertically.
 void setStyle(ToolBarStyle style)
          Alter the view of the ToolBar to display either icons only, text only, or both.
 void setToolTips(boolean enable)
          Sets if the tooltips of the ToolBar should be active or not.
 
Methods inherited from class org.gnu.gtk.Container
add, addListener, getBorderWidth, getEventListenerClass, getEventType, getResizeMode, remove, removeListener, resizeChildren, setBorderWidth, setResizeMode
 
Methods inherited from class org.gnu.gtk.Widget
activate, addListener, addListener, addListener, addListener, addListener, addListener, createContext, createLayout, destroy, draw, drawArea, drawArea, getAccessible, getColormap, getContext, getModifierStyle, getName, getParent, getParentWindow, getPointer, getSensitive, getStyle, getToplevel, grabDefault, grabFocus, hasFocus, hide, hideAll, intersect, isAncestor, makeWidget, modifyStyle, popColormap, pushColormap, realize, removeListener, removeListener, removeListener, removeListener, removeListener, removeListener, reparent, setBackgroundColor, setBaseColor, setColormap, setDoubleBuffered, setDragDestination, setDragSource, setFont, setForegroundColor, setMinimumSize, setName, setNoDragDestination, setNoDragSource, setSensitive, setTextColor, shapeCombineMask, show, showAll
 
Methods inherited from class org.gnu.glib.GObject
addEventHandler, addEventHandler, addEventHandler, addEventHandler, addEventHandler, addEventHandler, equals, getData, getHandle, removeEventHandler, setData
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ToolBar

public ToolBar()
Create a new ToolBar

Method Detail

appendWidget

public void appendWidget(Widget widget,
                         java.lang.String tooltip,
                         java.lang.String helpText)
Add a widget to the end of the toolbar.

Parameters:
widget - The widget to add to the end of the ToolBar.
tooltip - The text for the tooltip for this item.
helpText - Context sensitive help about this item.

prependWidget

public void prependWidget(Widget widget,
                          java.lang.String tooltip,
                          java.lang.String helpText)
Add a widget to the beginning of the toolbar.

Parameters:
widget - The widget to add to the beginning of the ToolBar.
tooltip - The text for the tooltip for this item.
helpText - Context sensitive help about this item.

insertWidget

public void insertWidget(Widget widget,
                         java.lang.String tooltip,
                         java.lang.String helpText,
                         int index)
Insert a Widget in the ToolBar at the given position

Parameters:
widget - The widget to add to the ToolBar.
tooltip - The text for the tooltip for this item.
helpText - Context sensitive help about this item.
index - The location in the ToolBar to insert this Widget.

appendSpace

public void appendSpace()
Add a space to the end of the ToolBar.


prependSpace

public void prependSpace()
Add a space to the beginning of the ToolBar.


insertSpace

public void insertSpace(int position)
Insert a space in the ToolBar at the specified location.

Parameters:
position - The location to insert the space.

removeSpace

public void removeSpace(int position)
Remove a space from the ToolBar.

Parameters:
position - The position of the space to remove.

setOrientation

public void setOrientation(Orientation orientation)
Set whether the ToolBar should appear horizontally or vertically.

Parameters:
orientation - Specifies the direction of the ToolBar.

setStyle

public void setStyle(ToolBarStyle style)
Alter the view of the ToolBar to display either icons only, text only, or both.

Parameters:
style - Determines how to display the items.

setToolTips

public void setToolTips(boolean enable)
Sets if the tooltips of the ToolBar should be active or not.

Parameters:
enable - Should the tooltips be enabled.

setIconSize

public void setIconSize(IconSize iconSize)
Sets the size of the stock icons in the ToolBar.

Parameters:
iconSize - The size of the icons.

getType

public static Type getType()
Retrieve the runtime type used by the GLib library.


Please send any bug reports, comments, or suggestions for the API or documentation to java-gnome-developer@lists.sf.net