com.smartgwt.client.widgets.tab
Class TabSet

java.lang.Object
  extended by com.google.gwt.user.client.ui.UIObject
      extended by com.google.gwt.user.client.ui.Widget
          extended by com.smartgwt.client.widgets.BaseWidget
              extended by com.smartgwt.client.widgets.Canvas
                  extended by com.smartgwt.client.widgets.tab.TabSet
All Implemented Interfaces:
HasHandlers, EventListener, HasClickHandlers, HasDoubleClickHandlers, HasDragMoveHandlers, HasDragRepositionMoveHandlers, HasDragRepositionStartHandlers, HasDragRepositionStopHandlers, HasDragResizeMoveHandlers, HasDragResizeStartHandlers, HasDragResizeStopHandlers, HasDragStartHandlers, HasDragStopHandlers, HasDropHandlers, HasDropMoveHandlers, HasDropOutHandlers, HasDropOverHandlers, HasFocusChangedHandlers, HasHoverHandlers, HasHoverHiddenHandlers, HasKeyDownHandlers, HasKeyPressHandlers, HasMouseDownHandlers, HasMouseMoveHandlers, HasMouseOutHandlers, HasMouseOverHandlers, HasMouseStillDownHandlers, HasMouseUpHandlers, HasMouseWheelHandlers, HasResizedHandlers, HasRightMouseDownHandlers, HasScrolledHandlers, HasShowContextMenuHandlers, HasCloseClickHandlers, HasTabDeselectedHandlers, HasTabIconClickHandlers, HasTabSelectedHandlers

public class TabSet
extends Canvas
implements HasCloseClickHandlers, HasTabIconClickHandlers, HasTabSelectedHandlers, HasTabDeselectedHandlers

The TabSet class allows components on several panes to share the same space. The tabs at the top can be selected by the user to show each pane.

Tabs are configured via the tabs property, each of which has a pane property which will be displayed in the main pane when that tab is selected.


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.smartgwt.client.widgets.BaseWidget
config, configOnly, id, isElementSet, scClassName
 
Fields inherited from class com.google.gwt.user.client.ui.UIObject
DEBUG_ID_PREFIX
 
Constructor Summary
TabSet()
           
TabSet(JavaScriptObject jsObj)
           
 
Method Summary
 HandlerRegistration addCloseClickHandler(CloseClickHandler handler)
          Add a onCloseClick handler.
 void addTab(Tab tab)
          Add a tab
 void addTab(Tab tab, int position)
          Add a tab
 HandlerRegistration addTabDeselectedHandler(TabDeselectedHandler handler)
          Add a tabDeselected handler.
 HandlerRegistration addTabIconClickHandler(TabIconClickHandler handler)
          Add a tabIconClick handler.
 HandlerRegistration addTabSelectedHandler(TabSelectedHandler handler)
          Add a tabSelected handler.
protected  JavaScriptObject create()
           
 void disableTab(int tabIndex)
          If the specified tab is enabled, disable it now.
 void disableTab(String ID)
          If the specified tab is enabled, disable it now.
 void disableTab(Tab tab)
          If the specified tab is enabled, disable it now.
 void enableTab(int tabIndex)
          If the specified tab is disabled, enable it now.
 void enableTab(String ID)
          If the specified tab is disabled, enable it now.
 void enableTab(Tab tab)
          If the specified tab is disabled, enable it now.
 Boolean getAnimateTabScrolling()
          If showTabScroller is true, should tabs be scrolled into view via an animation when the user interacts with the scroller buttons?
 Boolean getCanCloseTabs()
          Should tabs in this tabSet show an icon allowing the user to dismiss the tab by clicking on it directly.
 String getCloseTabIcon()
          Default src for the close icon for tabs to display if canCloseTabs is true.
 int getCloseTabIconSize()
          Size in pixels of the icon for closing tabs, displayed when canCloseTabs is true.
 Boolean getDestroyPanes()
          Whether BaseWidget.destroy() should be called on pane when it a tab is removed via removeTab(int)}.
 int getNumTabs()
          The number of tabs
static TabSet getOrCreateRef(JavaScriptObject jsObj)
           
 String getPaneContainerClassName()
          CSS style used for the paneContainer.
 Overflow getPaneContainerOverflow()
          Specifies the overflow of the pane container (the component that holds the pane contents for all tabs).
 String getPickerButtonHSrc()
          If showTabPicker is true, and symmetricPickerButton is set to true, this property governs the base URL for the picker button image, when displayed in a horizontal tab-bar [IE tabBarPosition is set to "top" or "bottom"].
 int getPickerButtonSize()
          If showTabPicker is true, this property governs the size of tab-picker button.
 String getPickerButtonSrc()
          If showTabPicker is true, this property governs the base URL for the picker button image, when symmetricPickerButton is set to false
 String getPickerButtonVSrc()
          If showTabPicker is true, and symmetricPickerButton is set to true, this property governs the base URL for the picker button image, when displayed in a verricaL tab-bar [IE tabBarPosition is set to "LEFT" or "right"].
 int getScrollerButtonSize()
          If showTabScroller is true, this property governs the size of scroller buttons.
 String getScrollerHSrc()
          If this TabSet is showing 'tab scroller buttons', and 'symmetricScroller' is true, this property governs the base URL for the tab bar back and forward scroller button images for horizontal tab bars [IE for tab sets with 'tabBarPosition' set to "top" or "bottom"].
 String getScrollerSrc()
          If this TabSet is showing 'tab scroller buttons', and 'symmetricScroller' is false, this property governs the base URL for the tab bar back and forward scroller button images.
 String getScrollerVSrc()
          If this TabSet is showing 'tab scroller buttons', and 'symmetricScroller' is true, this property governs the base URL for the tab bar back and forward scroller button images for vertical tab bars [IE for tab sets with 'tabBarPosition' set to "left" or "right"].
 Tab getSelectedTab()
          The currently selected tab.
 int getSelectedTabNumber()
          Returns the index of the currently selected tab object.
 Boolean getShowPaneContainerEdges()
          Should the paneContainer for this tabset show 'edges'.
 Boolean getShowPartialEdges()
          If the paneContainer for this tab set is showing 'edges', setting this attribute to true will set the paneContainer to show 'customEdges' for the three sides opposing the tabBarPosition.
 Boolean getShowTabPicker()
          If there is not enough space to display all the tab-buttons in this tabSet, should a drop-down "picker" be displayed to allow selection of tabs that are clipped?
 Boolean getShowTabScroller()
          If there is not enough space to display all the tab-buttons in this tabSet, should scroller buttons be displayed to allow access to tabs that are clipped?
 String getSkinImgDir()
          Default directory for skin images (those defined by the class), relative to the Page-wide Page.getSkinDir().
 Boolean getSymmetricEdges()
          If this tabSet will 'show edges' for the paneContainer, this property determines whether the same edge media will be used regardless of the tab bar position, or whether different media should be used (necessary if the edge appearance is not symmetrical on all sides).
 Boolean getSymmetricPickerButton()
          If this TabSet is showing a 'tab picker button', this property determines whether the pickerButtonHSrc and pickerButtonVSrc media will be used for vertical and horizontal tab-bar picker buttons, or whether separate media should be used for each possible 'tabBarPosition' based on the pickerButtonSrc property for this tabSet.
 Boolean getSymmetricScroller()
          If this TabSet is showing 'tab scroller buttons', this property determines whether the scrollerHSrc and scrollerVSrc media will be used for vertical and horizontal tab-bar scroller buttons, or whether separate media should be used for each possible 'tabBarPosition' based on the scrollerSrc property for this tabSet.
 Tab getTab(int tabIndex)
          Get the live Canvas representing a tab by index or ID.
 Tab getTab(String ID)
          Get the live Canvas representing a tab by index or ID.
 Side getTabBarAlign()
          Alignment of the tabBar.
 Side getTabBarPosition()
          Which side of the TabSet the TabBar should appear on.
 int getTabBarThickness()
          Thickness of tabBar, applies to either orientation (specifies height for horizontal, width for vertical orientation).
 Tab[] getTabs()
          The tabs
static void preloadImages()
          Preload primary tab skin images.
 void removeTab(int tabIndex)
          Remove a tab.
 void removeTab(String ID)
          Remove a tab.
 void removeTab(Tab tab)
          Remove a tab.
 void removeTabs(int[] tabIndexes)
          Remove one or more tabs.
 void removeTabs(String[] ids)
          Remove one or more tabs.
 void scrollBack()
          If there is not enough space to display all the tabs in this tabSet, this method will scroll the previous tab (that first tab that is clipped at the beginning of the tab-bar) into view.
 void scrollForward()
          If there is not enough space to display all the tabs in this tabSet, this method will scroll the next tab (that first tab that is clipped at the end of the tab-bar) into view.
 void selectTab(int tabIndex)
          Select a tab.
 void selectTab(String ID)
          Select a tab.
 void selectTab(Tab tab)
          Select a tab.
 void setAnimateTabScrolling(Boolean animateTabScrolling)
          If showTabScroller is true, should tabs be scrolled into view via an animation when the user interacts with the scroller buttons?
 void setCanCloseTabs(Boolean canCloseTabs)
          Should tabs in this tabSet show an icon allowing the user to dismiss the tab by clicking on it directly.
 void setCloseTabIcon(String closeTabIcon)
          Default src for the close icon for tabs to display if canCloseTabs is true.
 void setCloseTabIconSize(int closeTabIconSize)
          Size in pixels of the icon for closing tabs, displayed when canCloseTabs is true.
 void setDestroyPanes(Boolean destroyPanes)
          Whether BaseWidget.destroy() should be called on pane when it a tab is removed via removeTab(int)}.
 void setPaneContainerClassName(String paneContainerClassName)
          CSS style used for the paneContainer.
 void setPaneContainerOverflow(Overflow paneContainerOverflow)
          Specifies the overflow of the pane container (the component that holds the pane contents for all tabs).
 void setPickerButtonHSrc(String pickerButtonHSrc)
          If showTabPicker is true, and symmetricPickerButton is set to true, this property governs the base URL for the picker button image, when displayed in a horizontal tab-bar [IE tabBarPosition is set to "top" or "bottom"].
 void setPickerButtonSize(int pickerButtonSize)
          If showTabPicker is true, this property governs the size of tab-picker button.
 void setPickerButtonSrc(String pickerButtonSrc)
          If showTabPicker is true, this property governs the base URL for the picker button image, when symmetricPickerButton is set to false
 void setPickerButtonVSrc(String pickerButtonVSrc)
          If showTabPicker is true, and symmetricPickerButton is set to true, this property governs the base URL for the picker button image, when displayed in a verricaL tab-bar [IE tabBarPosition is set to "LEFT" or "right"].
 void setScrollerButtonSize(int scrollerButtonSize)
          If showTabScroller is true, this property governs the size of scroller buttons.
 void setScrollerHSrc(String scrollerHSrc)
          If this TabSet is showing 'tab scroller buttons', and 'symmetricScroller' is true, this property governs the base URL for the tab bar back and forward scroller button images for horizontal tab bars [IE for tab sets with 'tabBarPosition' set to "top" or "bottom"].
 void setScrollerSrc(String scrollerSrc)
          If this TabSet is showing 'tab scroller buttons', and 'symmetricScroller' is false, this property governs the base URL for the tab bar back and forward scroller button images.
 void setScrollerVSrc(String scrollerVSrc)
          If this TabSet is showing 'tab scroller buttons', and 'symmetricScroller' is true, this property governs the base URL for the tab bar back and forward scroller button images for vertical tab bars [IE for tab sets with 'tabBarPosition' set to "left" or "right"].
 void setSelectedTab(int selectedTab)
          Specifies the index of the initially selected tab.
 void setShowPaneContainerEdges(Boolean showPaneContainerEdges)
          Should the paneContainer for this tabset show 'edges'.
 void setShowPartialEdges(Boolean showPartialEdges)
          If the paneContainer for this tab set is showing 'edges', setting this attribute to true will set the paneContainer to show 'customEdges' for the three sides opposing the tabBarPosition.
 void setShowTabPicker(Boolean showTabPicker)
          If there is not enough space to display all the tab-buttons in this tabSet, should a drop-down "picker" be displayed to allow selection of tabs that are clipped?
 void setShowTabScroller(Boolean showTabScroller)
          If there is not enough space to display all the tab-buttons in this tabSet, should scroller buttons be displayed to allow access to tabs that are clipped?
 void setSkinImgDir(String skinImgDir)
          Default directory for skin images (those defined by the class), relative to the Page-wide Page.getSkinDir().
 void setSymmetricEdges(Boolean symmetricEdges)
          If this tabSet will 'show edges' for the paneContainer, this property determines whether the same edge media will be used regardless of the tab bar position, or whether different media should be used (necessary if the edge appearance is not symmetrical on all sides).
 void setSymmetricPickerButton(Boolean symmetricPickerButton)
          If this TabSet is showing a 'tab picker button', this property determines whether the pickerButtonHSrc and pickerButtonVSrc media will be used for vertical and horizontal tab-bar picker buttons, or whether separate media should be used for each possible 'tabBarPosition' based on the pickerButtonSrc property for this tabSet.
 void setSymmetricScroller(Boolean symmetricScroller)
          If this TabSet is showing 'tab scroller buttons', this property determines whether the scrollerHSrc and scrollerVSrc media will be used for vertical and horizontal tab-bar scroller buttons, or whether separate media should be used for each possible 'tabBarPosition' based on the scrollerSrc property for this tabSet.
 void setTabBarAlign(Side tabBarAlign)
          Alignment of the tabBar.
 void setTabBarControls(Object... tabBarControls)
          This property determines what controls should show up after the tabBar for this tabSet.
 void setTabBarPosition(Side tabBarPosition)
          Which side of the TabSet the TabBar should appear on.
 void setTabBarThickness(int tabBarThickness)
          Thickness of tabBar, applies to either orientation (specifies height for horizontal, width for vertical orientation).
 void setTabIcon(int tabIndex, String iconURL)
          Changes the icon of a tab
 void setTabIcon(String ID, String iconURL)
          Changes the icon of a tab
 void setTabIcon(Tab tab, String iconURL)
          Changes the icon of a tab
 void setTabPane(int tabIndex, Canvas pane)
          Apply a new pane to an existing tab in this tabSet
 void setTabPane(String tabID, Canvas pane)
          Apply a new pane to an existing tab in this tabSet
 void setTabs(Tab... tabs)
           
 void setTabTitle(int tabIndex, String title)
          Changes the title of a tab
 void setTabTitle(String ID, String title)
          Changes the title of a tab
 void setTabTitle(Tab tab, String title)
          Changes the title of a tab
 void updateTab(int tabIndex, Canvas pane)
           
 void updateTab(Tab tab, Canvas pane)
           
 
Methods inherited from class com.smartgwt.client.widgets.Canvas
addChild, addChild, addChild, addClickHandler, addDoubleClickHandler, addDragMoveHandler, addDragRepositionMoveHandler, addDragRepositionStartHandler, addDragRepositionStopHandler, addDragResizeMoveHandler, addDragResizeStartHandler, addDragResizeStopHandler, addDragStartHandler, addDragStopHandler, addDropHandler, addDropMoveHandler, addDropOutHandler, addDropOverHandler, addFocusChangedHandler, addHoverHandler, addHoverHiddenHandler, addKeyDownHandler, addKeyPressHandler, addMouseDownHandler, addMouseMoveHandler, addMouseOutHandler, addMouseOverHandler, addMouseStillDownHandler, addMouseUpHandler, addMouseWheelHandler, addPeer, addPeer, addResizedHandler, addRightMouseDownHandler, addScrolledHandler, addShowContextMenuHandler, addStyleName, adjustForContent, animateFade, animateFade, animateFade, animateHide, animateHide, animateHide, animateMove, animateMove, animateMove, animateMove, animateRect, animateRect, animateRect, animateResize, animateResize, animateResize, animateScroll, animateScroll, animateScroll, animateShow, animateShow, animateShow, blur, bringToFront, clear, clickMaskUp, clickMaskUp, contains, contains, containsEvent, containsFocus, containsPoint, containsPoint, convertToCanvasArray, disable, enable, focus, getAbsoluteLeft, getAbsoluteTop, getAccessKey, getAnimateAcceleration, getAnimateFadeTime, getAnimateHideAcceleration, getAnimateHideTime, getAnimateMoveAcceleration, getAnimateMoveTime, getAnimateRectAcceleration, getAnimateRectTime, getAnimateResizeAcceleration, getAnimateResizeTime, getAnimateScrollAcceleration, getAnimateScrollTime, getAnimateShowAcceleration, getAnimateShowTime, getAnimateTime, getAppImgDir, getAutoShowParent, getBackgroundImage, getBackgroundPosition, getBackgroundRepeat, getBorder, getBottom, getById, getCanAcceptDrop, getCanDrag, getCanDragReposition, getCanDragResize, getCanDragScroll, getCanDrop, getCanDropBefore, getCanFocus, getCanHover, getCanSelectText, getChildren, getChildrenSnapResizeToGrid, getChildrenSnapToGrid, getContents, getContextMenu, getCursor, getDataPath, getDefaultHeight, getDefaultWidth, getDestroyed, getDestroying, getDisabled, getDisabledCursor, getDoubleClickDelay, getDragAppearance, getDragIntersectStyle, getDragOpacity, getDragRepositionCursor, getDragScrollDelay, getDragStartDistance, getDragTarget, getDragType, getDynamicContents, getEdgeBackgroundColor, getEdgeCenterBackgroundColor, getEdgeImage, getEdgeOffset, getEdgeOpacity, getEdgeShowCenter, getEdgeSize, getExtraSpace, getFullDataPath, getGroupTitle, getHeight, getHeightAsString, getHoverAlign, getHoverDelay, getHoverHeight, getHoverHTML, getHoverMoveWithMouse, getHoverOpacity, getHoverStyle, getHoverVAlign, getHoverWidth, getHoverWrap, getHSnapOrigin, getHSnapOrigin, getHSnapPosition, getHSnapPosition, getHtmlPosition, getImgURL, getImgURL, getInnerContentHeight, getInnerContentWidth, getInnerHeight, getInnerWidth, getIsGroup, getLeft, getLeftAsString, getMargin, getMatchElement, getMaxHeight, getMaxWidth, getMinHeight, getMinWidth, getMouseStillDownDelay, getMouseStillDownInitialDelay, getNextZIndex, getNoDoubleClicks, getOffsetHeight, getOffsetWidth, getOffsetX, getOffsetY, getOpacity, getOverflow, getPadding, getPageBottom, getPageLeft, getPageRect, getPageRight, getPageTop, getParentElement, getPercentBox, getPosition, getPrefix, getPrompt, getRect, getRedrawOnResize, getResizeBarTarget, getRight, getScrollbarSize, getScrollBottom, getScrollHeight, getScrollLeft, getScrollRight, getScrollTop, getScrollWidth, getShadowDepth, getShadowImage, getShadowOffset, getShadowSoftness, getShowCustomScrollbars, getShowDragShadow, getShowEdges, getShowHover, getShowResizeBar, getShowShadow, getSnapAxis, getSnapEdge, getSnapHDirection, getSnapHGap, getSnapOffsetLeft, getSnapOffsetTop, getSnapOnDrop, getSnapResizeToGrid, getSnapTo, getSnapToGrid, getSnapVDirection, getSnapVGap, getStyleName, getTabIndex, getTitle, getTooltip, getTop, getTopAsString, getValuesManager, getViewportHeight, getViewportWidth, getVisibility, getVisibleHeight, getVisibleWidth, getVSnapOrigin, getVSnapOrigin, getVSnapPosition, getVSnapPosition, getWidth, getWidthAsString, getZIndex, handleHover, hide, hideClickMask, hideClickMask, hideContextMenu, imgHTML, imgHTML, imgHTML, intersects, isDirty, isDisabled, isDrawn, isVisible, keyUp, layoutChildren, linkHTML, linkHTML, markForDestroy, markForRedraw, markForRedraw, moveAbove, moveBelow, moveBy, moveTo, parentResized, redraw, redraw, removeChild, removeChild, resizeBy, resizeTo, resizeTo, scrollBy, scrollByPercent, scrollTo, scrollTo, scrollToBottom, scrollToLeft, scrollToPercent, scrollToRight, scrollToTop, sendToBack, setAccessKey, setAlign, setAnimateAcceleration, setAnimateFadeTime, setAnimateHideAcceleration, setAnimateHideTime, setAnimateMoveAcceleration, setAnimateMoveTime, setAnimateRectAcceleration, setAnimateRectTime, setAnimateResizeAcceleration, setAnimateResizeTime, setAnimateScrollAcceleration, setAnimateScrollTime, setAnimateShowAcceleration, setAnimateShowTime, setAnimateTime, setAppImgDir, setAutoHeight, setAutoShowParent, setAutoWidth, setBackgroundColor, setBackgroundImage, setBackgroundPosition, setBackgroundRepeat, setBorder, setBottom, setCanAcceptDrop, setCanDrag, setCanDragReposition, setCanDragResize, setCanDragScroll, setCanDrop, setCanDropBefore, setCanFocus, setCanHover, setCanSelectText, setChildren, setChildrenSnapResizeToGrid, setChildrenSnapToGrid, setContents, setContextMenu, setCursor, setDataPath, setDefaultHeight, setDefaultWidth, setDisabled, setDisabledCursor, setDoubleClickDelay, setDragAppearance, setDragIntersectStyle, setDragOpacity, setDragRepositionCursor, setDragScrollDelay, setDragStartDistance, setDragTarget, setDragType, setDropTypes, setDynamicContents, setEdgeBackgroundColor, setEdgeCenterBackgroundColor, setEdgeImage, setEdgeMarginSize, setEdgeOffset, setEdgeOpacity, setEdgeShowCenter, setEdgeSize, setExtraSpace, setGroupTitle, setHeight, setHeight, setHeight100, setHoverAlign, setHoverDelay, setHoverHeight, setHoverMoveWithMouse, setHoverOpacity, setHoverStyle, setHoverVAlign, setHoverWidth, setHoverWrap, setHtmlPosition, setImage, setImage, setIsGroup, setKeepInParentRect, setKeepInParentRect, setLayoutAlign, setLayoutAlign, setLeft, setLeft, setMargin, setMatchElement, setMaxHeight, setMaxWidth, setMinHeight, setMinWidth, setMouseStillDownDelay, setMouseStillDownInitialDelay, setNoDoubleClicks, setOpacity, setOverflow, setPadding, setPageLeft, setPageTop, setParentElement, setPercentBox, setPosition, setPrefix, setPrompt, setRect, setRect, setRedrawOnResize, setResizeBarTarget, setResizeFrom, setRight, setScrollbarSize, setShadowDepth, setShadowImage, setShadowOffset, setShadowSoftness, setShowCustomScrollbars, setShowDragShadow, setShowEdges, setShowHover, setShowResizeBar, setShowShadow, setSmoothFade, setSnapAxis, setSnapEdge, setSnapHDirection, setSnapHGap, setSnapOffsetLeft, setSnapOffsetTop, setSnapOnDrop, setSnapResizeToGrid, setSnapTo, setSnapToGrid, setSnapVDirection, setSnapVGap, setStyleName, setTabIndex, setTitle, setTooltip, setTop, setTop, setValuesManager, setVisibility, setVisible, setWidth, setWidth, setWidth100, setZIndex, shouldDragScroll, show, showClickMask, showNextTo, showNextTo, showPrintPreview, updateHover, updateHover, updateShadow, visibleAtPoint, visibleAtPoint, willAcceptDrop
 
Methods inherited from class com.smartgwt.client.widgets.BaseWidget
addDrawHandler, destroy, doAddHandler, doInit, doOnRender, draw, equals, error, errorIfNotCreated, fireEvent, getAttribute, getAttributeAsBoolean, getAttributeAsDate, getAttributeAsDouble, getAttributeAsElement, getAttributeAsFloat, getAttributeAsInt, getAttributeAsJavaScriptObject, getAttributeAsMap, getAttributeAsString, getAttributeAsStringArray, getConfig, getDOM, getElement, getElement, getHandlerCount, getID, getInnerHTML, getJsObj, getOrCreateJsObj, getRef, hashCode, isConfigOnly, isCreated, onDestroy, onDraw, onInit, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setConfig, setConfigOnly, setDragTracker, setElement, setHtmlElement, setID, setNullProperty, setPosition, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, toString
 
Methods inherited from class com.google.gwt.user.client.ui.Widget
addDomHandler, addHandler, delegateEvent, doAttachChildren, doDetachChildren, getLayoutData, getParent, isAttached, isOrWasAttached, onAttach, onBrowserEvent, onDetach, onLoad, onUnload, removeFromParent, setLayoutData, sinkEvents
 
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, 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
 

Constructor Detail

TabSet

public TabSet()

TabSet

public TabSet(JavaScriptObject jsObj)
Method Detail

getOrCreateRef

public static TabSet getOrCreateRef(JavaScriptObject jsObj)

create

protected JavaScriptObject create()
Overrides:
create in class Canvas

setTabBarPosition

public void setTabBarPosition(Side tabBarPosition)
                       throws IllegalStateException
Which side of the TabSet the TabBar should appear on.

Parameters:
tabBarPosition - tabBarPosition Default value is Canvas.TOP
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getTabBarPosition

public Side getTabBarPosition()
Which side of the TabSet the TabBar should appear on.

Returns:
Side

setTabBarAlign

public void setTabBarAlign(Side tabBarAlign)
                    throws IllegalStateException
Alignment of the tabBar.

If the position of the tabBar is "top" or "bottom", then alignment must be "left" or "right" and defaults to "left".

If the position of the tabBar is "left" or "right", then the alignment must be "top" or "bottom" and defaults to "top".

Parameters:
tabBarAlign - tabBarAlign Default value is see below
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getTabBarAlign

public Side getTabBarAlign()
Alignment of the tabBar.

If the position of the tabBar is "top" or "bottom", then alignment must be "left" or "right" and defaults to "left".

If the position of the tabBar is "left" or "right", then the alignment must be "top" or "bottom" and defaults to "top".

Returns:
Side

setTabBarThickness

public void setTabBarThickness(int tabBarThickness)
Thickness of tabBar, applies to either orientation (specifies height for horizontal, width for vertical orientation). Note that overriding this value for TabSets that are skinned with images generally means providing new media for the borders.

Parameters:
tabBarThickness - tabBarThickness Default value is 21

getTabBarThickness

public int getTabBarThickness()
Thickness of tabBar, applies to either orientation (specifies height for horizontal, width for vertical orientation). Note that overriding this value for TabSets that are skinned with images generally means providing new media for the borders.

Returns:
int

setCanCloseTabs

public void setCanCloseTabs(Boolean canCloseTabs)
Should tabs in this tabSet show an icon allowing the user to dismiss the tab by clicking on it directly. May be overridden for individual tabs by setting canClose.

The URL for this icon's image will be derived from closeTabIcon by default, but may be overridden by explicitly specifying closeIcon.

Note: Currently, tabs can only show a single icon, so a closable tab will show the close icon only even if icon is set. To work around this, add the icon as an HTML <img> tag to the title property, for example:

    title :
 "" + isc.Canvas.imgHTML("myIcon.png") + " Tab Title"
 

Parameters:
canCloseTabs - canCloseTabs Default value is null

getCanCloseTabs

public Boolean getCanCloseTabs()
Should tabs in this tabSet show an icon allowing the user to dismiss the tab by clicking on it directly. May be overridden for individual tabs by setting canClose.

The URL for this icon's image will be derived from closeTabIcon by default, but may be overridden by explicitly specifying closeIcon.

Note: Currently, tabs can only show a single icon, so a closable tab will show the close icon only even if icon is set. To work around this, add the icon as an HTML <img> tag to the title property, for example:

    title :
 "" + isc.Canvas.imgHTML("myIcon.png") + " Tab Title"
 

Returns:
Boolean

setCloseTabIcon

public void setCloseTabIcon(String closeTabIcon)
                     throws IllegalStateException
Default src for the close icon for tabs to display if canCloseTabs is true.

Parameters:
closeTabIcon - closeTabIcon Default value is [SKIN]/TabSet/close.png
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getCloseTabIcon

public String getCloseTabIcon()
Default src for the close icon for tabs to display if canCloseTabs is true.

Returns:
String

setCloseTabIconSize

public void setCloseTabIconSize(int closeTabIconSize)
                         throws IllegalStateException
Size in pixels of the icon for closing tabs, displayed when canCloseTabs is true.

Parameters:
closeTabIconSize - closeTabIconSize Default value is 16
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getCloseTabIconSize

public int getCloseTabIconSize()
Size in pixels of the icon for closing tabs, displayed when canCloseTabs is true.

Returns:
int

setShowTabScroller

public void setShowTabScroller(Boolean showTabScroller)
                        throws IllegalStateException
If there is not enough space to display all the tab-buttons in this tabSet, should scroller buttons be displayed to allow access to tabs that are clipped?

Parameters:
showTabScroller - showTabScroller Default value is true
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getShowTabScroller

public Boolean getShowTabScroller()
If there is not enough space to display all the tab-buttons in this tabSet, should scroller buttons be displayed to allow access to tabs that are clipped?

Returns:
Boolean

setShowTabPicker

public void setShowTabPicker(Boolean showTabPicker)
                      throws IllegalStateException
If there is not enough space to display all the tab-buttons in this tabSet, should a drop-down "picker" be displayed to allow selection of tabs that are clipped?

Parameters:
showTabPicker - showTabPicker Default value is true
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getShowTabPicker

public Boolean getShowTabPicker()
If there is not enough space to display all the tab-buttons in this tabSet, should a drop-down "picker" be displayed to allow selection of tabs that are clipped?

Returns:
Boolean

setAnimateTabScrolling

public void setAnimateTabScrolling(Boolean animateTabScrolling)
                            throws IllegalStateException
If showTabScroller is true, should tabs be scrolled into view via an animation when the user interacts with the scroller buttons?

Parameters:
animateTabScrolling - animateTabScrolling Default value is true
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getAnimateTabScrolling

public Boolean getAnimateTabScrolling()
If showTabScroller is true, should tabs be scrolled into view via an animation when the user interacts with the scroller buttons?

Returns:
Boolean

setScrollerButtonSize

public void setScrollerButtonSize(int scrollerButtonSize)
                           throws IllegalStateException
If showTabScroller is true, this property governs the size of scroller buttons. Applied as the width of buttons if the tabBar is horizontal, or the height if tabBar is vertical. Note that the other dimension is determined by 'this.tabBarThickness'

Parameters:
scrollerButtonSize - scrollerButtonSize Default value is 16
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getScrollerButtonSize

public int getScrollerButtonSize()
If showTabScroller is true, this property governs the size of scroller buttons. Applied as the width of buttons if the tabBar is horizontal, or the height if tabBar is vertical. Note that the other dimension is determined by 'this.tabBarThickness'

Returns:
int

setPickerButtonSize

public void setPickerButtonSize(int pickerButtonSize)
                         throws IllegalStateException
If showTabPicker is true, this property governs the size of tab-picker button. Applied as the width of buttons if the tabBar is horizontal, or the height if tabBar is vertical. Note that the other dimension is determined by 'this.tabBarThickness'

Parameters:
pickerButtonSize - pickerButtonSize Default value is 16
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getPickerButtonSize

public int getPickerButtonSize()
If showTabPicker is true, this property governs the size of tab-picker button. Applied as the width of buttons if the tabBar is horizontal, or the height if tabBar is vertical. Note that the other dimension is determined by 'this.tabBarThickness'

Returns:
int

setSkinImgDir

public void setSkinImgDir(String skinImgDir)
                   throws IllegalStateException
Default directory for skin images (those defined by the class), relative to the Page-wide Page.getSkinDir().

Overrides:
setSkinImgDir in class Canvas
Parameters:
skinImgDir - skinImgDir Default value is "images/TabSet/"
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getSkinImgDir

public String getSkinImgDir()
Default directory for skin images (those defined by the class), relative to the Page-wide Page.getSkinDir().

Overrides:
getSkinImgDir in class Canvas
Returns:
String

setSymmetricScroller

public void setSymmetricScroller(Boolean symmetricScroller)
                          throws IllegalStateException
If this TabSet is showing 'tab scroller buttons', this property determines whether the scrollerHSrc and scrollerVSrc media will be used for vertical and horizontal tab-bar scroller buttons, or whether separate media should be used for each possible 'tabBarPosition' based on the scrollerSrc property for this tabSet.

Parameters:
symmetricScroller - symmetricScroller Default value is true
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getSymmetricScroller

public Boolean getSymmetricScroller()
If this TabSet is showing 'tab scroller buttons', this property determines whether the scrollerHSrc and scrollerVSrc media will be used for vertical and horizontal tab-bar scroller buttons, or whether separate media should be used for each possible 'tabBarPosition' based on the scrollerSrc property for this tabSet.

Returns:
Boolean

setScrollerSrc

public void setScrollerSrc(String scrollerSrc)
                    throws IllegalStateException
If this TabSet is showing 'tab scroller buttons', and 'symmetricScroller' is false, this property governs the base URL for the tab bar back and forward scroller button images.

Note that if 'symmetricScroller' is true, scrollerHSrc and scrollerVSrc will be used instead.

To get the path to the image to display, this base URL will be modified as follows:

For example - if the scrollerSrc is set to "[SKIN]scroll.gif", the image displayed for the back-scroller button on a tabSet with tabBarPosition set to "top" and symmetricScroller set to false would be one of "[SKIN]scroll_top_back.gif", "[SKIN]scroll_Down_top_back.gif", and "[SKIN]scroll_Disabled_top_back.gif".

Note that for best results the media should be sized to match the scroller button sizes, determined by tabBarThickness and scrollerButtonSize.

Parameters:
scrollerSrc - scrollerSrc Default value is "[SKIN]/scroll.gif"
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getScrollerSrc

public String getScrollerSrc()
If this TabSet is showing 'tab scroller buttons', and 'symmetricScroller' is false, this property governs the base URL for the tab bar back and forward scroller button images.

Note that if 'symmetricScroller' is true, scrollerHSrc and scrollerVSrc will be used instead.

To get the path to the image to display, this base URL will be modified as follows:

For example - if the scrollerSrc is set to "[SKIN]scroll.gif", the image displayed for the back-scroller button on a tabSet with tabBarPosition set to "top" and symmetricScroller set to false would be one of "[SKIN]scroll_top_back.gif", "[SKIN]scroll_Down_top_back.gif", and "[SKIN]scroll_Disabled_top_back.gif".

Note that for best results the media should be sized to match the scroller button sizes, determined by tabBarThickness and scrollerButtonSize.

Returns:
String

setScrollerHSrc

public void setScrollerHSrc(String scrollerHSrc)
                     throws IllegalStateException
If this TabSet is showing 'tab scroller buttons', and 'symmetricScroller' is true, this property governs the base URL for the tab bar back and forward scroller button images for horizontal tab bars [IE for tab sets with 'tabBarPosition' set to "top" or "bottom"].

Note that if 'symmetricScroller' is false, scrollerSrc will be used instead.

To get the path to the image to display, this base URL will be modified as follows:

For example - if the scrollerHSrc is set to "[SKIN]hscroll.gif", the image displayed for the back-scroller button on a tabSet with tabBarPosition set to "top" and symmetricScroller set to true would be one of "[SKIN]hscroll_back.gif", "[SKIN]hscroll_Down_back.gif", and "[SKIN]hscroll_Disabled_back.gif".

Note that for best results the media should be sized to match the scroller button sizes, determined by tabBarThickness and scrollerButtonSize.

Parameters:
scrollerHSrc - scrollerHSrc Default value is "[SKIN]hscroll.gif"
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getScrollerHSrc

public String getScrollerHSrc()
If this TabSet is showing 'tab scroller buttons', and 'symmetricScroller' is true, this property governs the base URL for the tab bar back and forward scroller button images for horizontal tab bars [IE for tab sets with 'tabBarPosition' set to "top" or "bottom"].

Note that if 'symmetricScroller' is false, scrollerSrc will be used instead.

To get the path to the image to display, this base URL will be modified as follows:

For example - if the scrollerHSrc is set to "[SKIN]hscroll.gif", the image displayed for the back-scroller button on a tabSet with tabBarPosition set to "top" and symmetricScroller set to true would be one of "[SKIN]hscroll_back.gif", "[SKIN]hscroll_Down_back.gif", and "[SKIN]hscroll_Disabled_back.gif".

Note that for best results the media should be sized to match the scroller button sizes, determined by tabBarThickness and scrollerButtonSize.

Returns:
String

setScrollerVSrc

public void setScrollerVSrc(String scrollerVSrc)
                     throws IllegalStateException
If this TabSet is showing 'tab scroller buttons', and 'symmetricScroller' is true, this property governs the base URL for the tab bar back and forward scroller button images for vertical tab bars [IE for tab sets with 'tabBarPosition' set to "left" or "right"].

Note that if 'symmetricScroller' is false, scrollerSrc will be used instead.

To get the path to the image to display, this base URL will be modified as follows:

For example - if the scrollerVSrc is set to "[SKIN]vscroll.gif", the image displayed for the back-scroller button on a tabSet with tabBarPosition set to "left" and symmetricScroller set to true would be one of "[SKIN]vscroll_back.gif", "[SKIN]vscroll_Down_back.gif", and "[SKIN]vscroll_Disabled_back.gif".

Note that for best results the media should be sized to match the scroller button sizes, determined by tabBarThickness and scrollerButtonSize.

Parameters:
scrollerVSrc - scrollerVSrc Default value is "[SKIN]vscroll.gif"
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getScrollerVSrc

public String getScrollerVSrc()
If this TabSet is showing 'tab scroller buttons', and 'symmetricScroller' is true, this property governs the base URL for the tab bar back and forward scroller button images for vertical tab bars [IE for tab sets with 'tabBarPosition' set to "left" or "right"].

Note that if 'symmetricScroller' is false, scrollerSrc will be used instead.

To get the path to the image to display, this base URL will be modified as follows:

For example - if the scrollerVSrc is set to "[SKIN]vscroll.gif", the image displayed for the back-scroller button on a tabSet with tabBarPosition set to "left" and symmetricScroller set to true would be one of "[SKIN]vscroll_back.gif", "[SKIN]vscroll_Down_back.gif", and "[SKIN]vscroll_Disabled_back.gif".

Note that for best results the media should be sized to match the scroller button sizes, determined by tabBarThickness and scrollerButtonSize.

Returns:
String

setSymmetricPickerButton

public void setSymmetricPickerButton(Boolean symmetricPickerButton)
                              throws IllegalStateException
If this TabSet is showing a 'tab picker button', this property determines whether the pickerButtonHSrc and pickerButtonVSrc media will be used for vertical and horizontal tab-bar picker buttons, or whether separate media should be used for each possible 'tabBarPosition' based on the pickerButtonSrc property for this tabSet.

Parameters:
symmetricPickerButton - symmetricPickerButton Default value is true
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getSymmetricPickerButton

public Boolean getSymmetricPickerButton()
If this TabSet is showing a 'tab picker button', this property determines whether the pickerButtonHSrc and pickerButtonVSrc media will be used for vertical and horizontal tab-bar picker buttons, or whether separate media should be used for each possible 'tabBarPosition' based on the pickerButtonSrc property for this tabSet.

Returns:
Boolean

setPickerButtonSrc

public void setPickerButtonSrc(String pickerButtonSrc)
                        throws IllegalStateException
If showTabPicker is true, this property governs the base URL for the picker button image, when symmetricPickerButton is set to false

Note that if symmetricPickerButton is true, the pickerButtonHSrc and pickerButtonVSrc properties will be used instead.

To get the path to the image to display, this base URL will be modified as follows:

Parameters:
pickerButtonSrc - pickerButtonSrc Default value is "[SKIN]/picker.gif"
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getPickerButtonSrc

public String getPickerButtonSrc()
If showTabPicker is true, this property governs the base URL for the picker button image, when symmetricPickerButton is set to false

Note that if symmetricPickerButton is true, the pickerButtonHSrc and pickerButtonVSrc properties will be used instead.

To get the path to the image to display, this base URL will be modified as follows:

Returns:
String

setPickerButtonHSrc

public void setPickerButtonHSrc(String pickerButtonHSrc)
                         throws IllegalStateException
If showTabPicker is true, and symmetricPickerButton is set to true, this property governs the base URL for the picker button image, when displayed in a horizontal tab-bar [IE tabBarPosition is set to "top" or "bottom"].

Note that if symmetricPickerButton is false, the pickerButtonSrc property will be used instead.

This base URL will have a suffix of "Down" appended when the user holds the mouse down over the button, and "Disabled" if the tabset as a whole is disabled.

Parameters:
pickerButtonHSrc - pickerButtonHSrc Default value is "[SKIN]hpicker.gif"
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getPickerButtonHSrc

public String getPickerButtonHSrc()
If showTabPicker is true, and symmetricPickerButton is set to true, this property governs the base URL for the picker button image, when displayed in a horizontal tab-bar [IE tabBarPosition is set to "top" or "bottom"].

Note that if symmetricPickerButton is false, the pickerButtonSrc property will be used instead.

This base URL will have a suffix of "Down" appended when the user holds the mouse down over the button, and "Disabled" if the tabset as a whole is disabled.

Returns:
String

setPickerButtonVSrc

public void setPickerButtonVSrc(String pickerButtonVSrc)
                         throws IllegalStateException
If showTabPicker is true, and symmetricPickerButton is set to true, this property governs the base URL for the picker button image, when displayed in a verricaL tab-bar [IE tabBarPosition is set to "LEFT" or "right"].

Note that if symmetricPickerButton is false, the pickerButtonSrc property will be used instead.

This base URL will have a suffix of "Down" appended when the user holds the mouse down over the button, and "Disabled" if the tabset as a whole is disabled.

Parameters:
pickerButtonVSrc - pickerButtonVSrc Default value is "[SKIN]vpicker.gif"
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getPickerButtonVSrc

public String getPickerButtonVSrc()
If showTabPicker is true, and symmetricPickerButton is set to true, this property governs the base URL for the picker button image, when displayed in a verricaL tab-bar [IE tabBarPosition is set to "LEFT" or "right"].

Note that if symmetricPickerButton is false, the pickerButtonSrc property will be used instead.

This base URL will have a suffix of "Down" appended when the user holds the mouse down over the button, and "Disabled" if the tabset as a whole is disabled.

Returns:
String

setPaneContainerClassName

public void setPaneContainerClassName(String paneContainerClassName)
CSS style used for the paneContainer.

Parameters:
paneContainerClassName - paneContainerClassName Default value is null

getPaneContainerClassName

public String getPaneContainerClassName()
CSS style used for the paneContainer.

Returns:
String

setPaneContainerOverflow

public void setPaneContainerOverflow(Overflow paneContainerOverflow)
Specifies the overflow of the pane container (the component that holds the pane contents for all tabs). By default this is set to "auto", meaning the pane container will automatically introduce scrolling when the pane contents exceed the TabSet's specified size.

For other values and their meaning, see Overflow Update paneContainerOverflow after creation.

Note : This is an advanced setting

Parameters:
paneContainerOverflow - new overflow setting. Default value is Canvas.AUTO

getPaneContainerOverflow

public Overflow getPaneContainerOverflow()
Specifies the overflow of the pane container (the component that holds the pane contents for all tabs). By default this is set to "auto", meaning the pane container will automatically introduce scrolling when the pane contents exceed the TabSet's specified size.

For other values and their meaning, see Overflow

Returns:
Overflow

setSymmetricEdges

public void setSymmetricEdges(Boolean symmetricEdges)
                       throws IllegalStateException
If this tabSet will 'show edges' for the paneContainer, this property determines whether the same edge media will be used regardless of the tab bar position, or whether different media should be used (necessary if the edge appearance is not symmetrical on all sides).

If this property is set to false the paneContainer edge image URLs will be prefixed with the tabBarPosition of the tabSet - for example "[SKIN]edge_top_T.gif" rather than just "[SKIN]edge_T.gif".

When symmetricEdges is false, custom edge sizes for the pane container may be specified via topEdgeSizes et al, and custom edge offsets via topEdgeOffsets et al.

Parameters:
symmetricEdges - symmetricEdges Default value is true
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getSymmetricEdges

public Boolean getSymmetricEdges()
If this tabSet will 'show edges' for the paneContainer, this property determines whether the same edge media will be used regardless of the tab bar position, or whether different media should be used (necessary if the edge appearance is not symmetrical on all sides).

If this property is set to false the paneContainer edge image URLs will be prefixed with the tabBarPosition of the tabSet - for example "[SKIN]edge_top_T.gif" rather than just "[SKIN]edge_T.gif".

When symmetricEdges is false, custom edge sizes for the pane container may be specified via topEdgeSizes et al, and custom edge offsets via topEdgeOffsets et al.

Returns:
Boolean

setShowPaneContainerEdges

public void setShowPaneContainerEdges(Boolean showPaneContainerEdges)
Should the paneContainer for this tabset show 'edges'.

Note : This is an advanced setting

Parameters:
showPaneContainerEdges - showPaneContainerEdges Default value is null

getShowPaneContainerEdges

public Boolean getShowPaneContainerEdges()
Should the paneContainer for this tabset show 'edges'.

Returns:
Boolean

setShowPartialEdges

public void setShowPartialEdges(Boolean showPartialEdges)
                         throws IllegalStateException
If the paneContainer for this tab set is showing 'edges', setting this attribute to true will set the paneContainer to show 'customEdges' for the three sides opposing the tabBarPosition.

Note : This is an advanced setting

Parameters:
showPartialEdges - showPartialEdges Default value is false
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getShowPartialEdges

public Boolean getShowPartialEdges()
If the paneContainer for this tab set is showing 'edges', setting this attribute to true will set the paneContainer to show 'customEdges' for the three sides opposing the tabBarPosition.

Returns:
Boolean

setDestroyPanes

public void setDestroyPanes(Boolean destroyPanes)
                     throws IllegalStateException
Whether BaseWidget.destroy() should be called on pane when it a tab is removed via removeTab(int)}.

An application might set this to false in order to re-use panes in different tabs or in different parts of the application.

Parameters:
destroyPanes - destroyPanes Default value is null
Throws:
IllegalStateException - this property cannot be changed after the component has been created

getDestroyPanes

public Boolean getDestroyPanes()
Whether BaseWidget.destroy() should be called on pane when it a tab is removed via removeTab(int)}.

An application might set this to false in order to re-use panes in different tabs or in different parts of the application.

Returns:
Boolean

addTabIconClickHandler

public HandlerRegistration addTabIconClickHandler(TabIconClickHandler handler)
Add a tabIconClick handler.

Method fired when the user clicks the icon for a tab, as specified via icon.

Default behavior will fire icon.click() if specified, with two parameters tab (a pointer to the tab object and tabSet a pointer to the tabSet instance.

Specified by:
addTabIconClickHandler in interface HasTabIconClickHandlers
Parameters:
handler - the tabIconClick handler
Returns:
HandlerRegistration used to remove this handler

scrollForward

public void scrollForward()
If there is not enough space to display all the tabs in this tabSet, this method will scroll the next tab (that first tab that is clipped at the end of the tab-bar) into view.


scrollBack

public void scrollBack()
If there is not enough space to display all the tabs in this tabSet, this method will scroll the previous tab (that first tab that is clipped at the beginning of the tab-bar) into view.


getSelectedTabNumber

public int getSelectedTabNumber()
Returns the index of the currently selected tab object.

Returns:
the index of the currently selected tab object

addTabSelectedHandler

public HandlerRegistration addTabSelectedHandler(TabSelectedHandler handler)
Add a tabSelected handler.

Notification fired when a tab is selected. Note that this will only fire if this tabSet is drawn. If a tab is selected before TabSet.draw() is called, the tabSelected() notification will fire on draw()

Specified by:
addTabSelectedHandler in interface HasTabSelectedHandlers
Parameters:
handler - the tabSelected handler
Returns:
HandlerRegistration used to remove this handler

addTabDeselectedHandler

public HandlerRegistration addTabDeselectedHandler(TabDeselectedHandler handler)
Add a tabDeselected handler.

Notification fired when a tab is deselected.

Specified by:
addTabDeselectedHandler in interface HasTabDeselectedHandlers
Parameters:
handler - the tabDeselected handler
Returns:
HandlerRegistration used to remove this handler

setSelectedTab

public void setSelectedTab(int selectedTab)
Specifies the index of the initially selected tab.

Parameters:
selectedTab - selectedTab Default value is 0

setTabs

public void setTabs(Tab... tabs)

selectTab

public void selectTab(int tabIndex)
Select a tab.

Parameters:
tabIndex - the tab index

selectTab

public void selectTab(String ID)
Select a tab.

Parameters:
ID - the tab ID

selectTab

public void selectTab(Tab tab)
Select a tab.

Parameters:
tab - the tab

setTabTitle

public void setTabTitle(int tabIndex,
                        String title)
Changes the title of a tab

Parameters:
tabIndex - the tab index
title - new title

setTabTitle

public void setTabTitle(String ID,
                        String title)
Changes the title of a tab

Parameters:
ID - the tab ID
title - new title

setTabTitle

public void setTabTitle(Tab tab,
                        String title)
Changes the title of a tab

Parameters:
tab - the tab
title - new title

setTabIcon

public void setTabIcon(int tabIndex,
                       String iconURL)
Changes the icon of a tab

Parameters:
tabIndex - the tab index
iconURL - new icon

setTabIcon

public void setTabIcon(String ID,
                       String iconURL)
Changes the icon of a tab

Parameters:
ID - the tab ID
iconURL - new icon

setTabIcon

public void setTabIcon(Tab tab,
                       String iconURL)
Changes the icon of a tab

Parameters:
tab - the tab
iconURL - new icon

enableTab

public void enableTab(int tabIndex)
If the specified tab is disabled, enable it now.

Parameters:
tabIndex - the tab index

enableTab

public void enableTab(String ID)
If the specified tab is disabled, enable it now.

Parameters:
ID - the tab id

enableTab

public void enableTab(Tab tab)
If the specified tab is disabled, enable it now.

Parameters:
tab - the tab

updateTab

public void updateTab(int tabIndex,
                      Canvas pane)

updateTab

public void updateTab(Tab tab,
                      Canvas pane)

disableTab

public void disableTab(int tabIndex)
If the specified tab is enabled, disable it now.

Parameters:
tabIndex - the tab index

disableTab

public void disableTab(String ID)
If the specified tab is enabled, disable it now.

Parameters:
ID - the tab id

disableTab

public void disableTab(Tab tab)
If the specified tab is enabled, disable it now.

Parameters:
tab - the tab

removeTab

public void removeTab(int tabIndex)
Remove a tab.

The pane associated with the removed tab is automatically destroyed when you call this method. To avoid this, call updateTab(int, com.smartgwt.client.widgets.Canvas) with null as the new pane immediately before removing the tab.

Parameters:
tabs - list of tabs, tabIDs, or tab numbers

removeTab

public void removeTab(String ID)
Remove a tab.

The pane associated with the removed tab is automatically destroyed when you call this method. To avoid this, call updateTab(int, com.smartgwt.client.widgets.Canvas) with null as the new pane immediately before removing the tab.

Parameters:
tabs - list of tabs, tabIDs, or tab numbers

removeTab

public void removeTab(Tab tab)
Remove a tab.

The pane associated with the removed tab is automatically destroyed when you call this method. To avoid this, call updateTab(int, com.smartgwt.client.widgets.Canvas) with null as the new pane immediately before removing the tab.

Parameters:
tabs - list of tabs, tabIDs, or tab numbers

removeTabs

public void removeTabs(int[] tabIndexes)
Remove one or more tabs. The pane(s) associated with the removed tab(s) is automatically destroyed when you call this method.

Parameters:
tabs - list of tabs, tabIDs, or tab numbers

removeTabs

public void removeTabs(String[] ids)
Remove one or more tabs. The pane(s) associated with the removed tab(s) is automatically destroyed when you call this method.

Parameters:
tabs - list of tabs, tabIDs, or tab numbers

getSelectedTab

public Tab getSelectedTab()
The currently selected tab.

Returns:
the currently selected Tab

getTab

public Tab getTab(int tabIndex)
Get the live Canvas representing a tab by index or ID. If passed a tab Canvas, just returns it.

Note that live Tab instances are not available until BaseWidget.draw().

The returned Tab is considered an internal component of the TabSet. In order to maximize forward compatibility, manipulate tabs through APIs such as a setTabTitle(int, java.lang.String) instead. Also note that a super-lightweight TabSet implementation may not use a separate Canvas per Tab, and code that accesses an manipulates Tabs as Canvases won't be compatible with that implementation.

Parameters:
tab -
Returns:
the tab Canvas, or null if not found or TabSet not drawn yet

getTab

public Tab getTab(String ID)
Get the live Canvas representing a tab by index or ID. If passed a tab Canvas, just returns it.

Note that live Tab instances are not available until BaseWidget.draw().

The returned Tab is considered an internal component of the TabSet. In order to maximize forward compatibility, manipulate tabs through APIs such as a setTabTitle(int, java.lang.String) instead. Also note that a super-lightweight TabSet implementation may not use a separate Canvas per Tab, and code that accesses an manipulates Tabs as Canvases won't be compatible with that implementation.

Parameters:
tab -
Returns:
the tab Canvas, or null if not found or TabSet not drawn yet

addTab

public void addTab(Tab tab)
Add a tab

Parameters:
tab - new tab

addTab

public void addTab(Tab tab,
                   int position)
Add a tab

Parameters:
tab - new tab
position - the position where tab should be added

getNumTabs

public int getNumTabs()
The number of tabs

Returns:
the number of tabs

getTabs

public Tab[] getTabs()
The tabs

Returns:
the tabs

setTabBarControls

public void setTabBarControls(Object... tabBarControls)
                       throws IllegalStateException
This property determines what controls should show up after the tabBar for this tabSet. Standard controls can be included using the strings "tabScroller" and "tabPicker". These show the standard controls to scroll to clipped tabs, or pick them directly from a menu, and show up only if showTabScroller or showTabPicker is true and there is not enough space available to show all the tabs in the tab-bar.

Additional controls can be included by adding any widget to this array. Controls will show up in the order in which they are specified. For example, the following code would add a button in the tabBar area, while preserving the normal behavior of the tabScroller and tabPicker:

 isc.TabSet.create({     width:300,     tabs : [         { title: "Tab one" }     ],     tabBarControls : [
        isc.ImgButton.create({             src:"[SKINIMG]/actions/add.png",             width:16, height:16,
       layoutAlign:"center"         }),         "tabScroller", "tabPicker"     ] }); 

Note : This is an advanced setting

Parameters:
tabBarControls - tabBarControls Default value is ["tabScroller", "tabPicker"]
Throws:
IllegalStateException - this property cannot be changed after the component has been created
See Also:
TabBarControls

setTabPane

public void setTabPane(int tabIndex,
                       Canvas pane)
Apply a new pane to an existing tab in this tabSet

Parameters:
tabIndex - Tab to update
pane - new Pane for the tab

setTabPane

public void setTabPane(String tabID,
                       Canvas pane)
Apply a new pane to an existing tab in this tabSet

Parameters:
tabID - Tab to update
pane - new Pane for the tab

addCloseClickHandler

public HandlerRegistration addCloseClickHandler(CloseClickHandler handler)
Add a onCloseClick handler.

When canCloseTabs is set, this notification method fired when the user clicks the "close" icon for a tab. Return false to cancel default behavior of removing the tab from the TabSet

Specified by:
addCloseClickHandler in interface HasCloseClickHandlers
Parameters:
handler - the onCloseClick handler
Returns:
HandlerRegistration used to remove this handler

preloadImages

public static void preloadImages()
Preload primary tab skin images.