Package org.zkoss.stateless.sul
Interface ITab
- All Superinterfaces:
IChildrenOfInputgroup<ITab>,IComponent<ITab>,IHtmlBasedComponent<ITab>,ILabelElement<ITab>,ILabelImageElement<ITab>,IXulElement<ITab>
Immutable
Tab component
Support @Action
| Name | Action Type |
|---|---|
| onClose | Denotes the close button is pressed by a user, and the component shall detach itself. |
| onSelect | ActionData: SelectData
Denotes user has selected a tab. onSelect is sent to both tab and tabbox. |
- Author:
- katherine
- See Also:
-
Tab
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic classBuilds instances of typeITab.static classBuilds an updater of typeITabforUiAgent.smartUpdate(Locator, SmartUpdater). -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionReturns the caption of this tab.default StringReturns the client widget class.default booleanReturns whether this tab is closable.default booleanReturns whether this tab is disabled.default booleanReturns whether this tab is selected.static ITabReturns the instance with the given label.static ITabReturns the instance with the given label and image.static ITabReturns the instance with the givenICaption.static ITabReturns the instance with the given id.static ITabReturns the instance with the given image.withCaption(ICaption<IAnyGroup> caption) Returns a copy ofthisimmutable component with the specifiedcaption.withClosable(boolean closable) Returns a copy ofthisimmutable component with the specifiedclosable.withDisabled(boolean disabled) Returns a copy ofthisimmutable component with the specifieddisabled.withSelected(boolean selected) Returns a copy ofthisimmutable component with the specifiedselected.Methods inherited from interface org.zkoss.stateless.sul.IComponent
getAction, getActions, getClientAttributes, getId, getMold, getWidgetListeners, getWidgetOverrides, isVisible, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withActions, withActions, withClientAttribute, withClientAttributes, withId, withMold, withVisible, withWidgetClass, withWidgetListener, withWidgetListeners, withWidgetOverride, withWidgetOverridesMethods inherited from interface org.zkoss.stateless.sul.IHtmlBasedComponent
getClientAction, getDraggable, getDroppable, getHeight, getHflex, getLeft, getRenderdefer, getSclass, getSkeleton, getStyle, getTabindex, getTooltiptext, getTop, getVflex, getWidth, getZclass, getZIndex, isFocus, withClientAction, withDraggable, withDroppable, withFocus, withHeight, withHflex, withLeft, withRenderdefer, withSclass, withSkeleton, withStyle, withTabindex, withTabindex, withTooltiptext, withTop, withVflex, withWidth, withZclass, withZIndexMethods inherited from interface org.zkoss.stateless.sul.ILabelElement
getLabel, withLabelMethods inherited from interface org.zkoss.stateless.sul.ILabelImageElement
getHoverImage, getIconSclass, getIconSclasses, getIconTooltip, getIconTooltips, getImage, isPreloadImage, withHoverImage, withIconSclass, withIconSclasses, withIconTooltip, withIconTooltips, withImage, withPreloadImageMethods inherited from interface org.zkoss.stateless.sul.IXulElement
getContext, getCtrlKeys, getPopup, getTooltip, withContext, withCtrlKeys, withPopup, withTooltip
-
Field Details
-
DEFAULT
Constant for default attributes of this immutable component.
-
-
Method Details
-
getWidgetClass
Returns the client widget class.Default:
"zul.tab.Tab"- Specified by:
getWidgetClassin interfaceIComponent<ITab>
-
isDisabled
default boolean isDisabled()Returns whether this tab is disabled.Default:
false. -
withDisabled
Returns a copy ofthisimmutable component with the specifieddisabled.Sets whether it is disabled.
- Parameters:
disabled-tureto disable this component.Default:
false.- Returns:
- A modified copy of the
thisobject
-
isClosable
default boolean isClosable()Returns whether this tab is closable. If closable, a button is displayed and theonCloseaction is sent if a user clicks the button.Default:
false. -
withClosable
Returns a copy ofthisimmutable component with the specifiedclosable.Sets whether this tab is closable. If closable, a button is displayed and the onClose action is sent if a user clicks the button.
- Parameters:
closable-tureto disable this component.Default:
false.- Returns:
- A modified copy of the
thisobject
-
isSelected
default boolean isSelected()Returns whether this tab is selected. -
withSelected
Returns a copy ofthisimmutable component with the specifiedselected.Sets whether this tab is selected.
- Parameters:
selected-tureto select this component.Default:
false.- Returns:
- A modified copy of the
thisobject
-
getCaption
Returns the caption of this tab. -
withCaption
Returns a copy ofthisimmutable component with the specifiedcaption.Sets the caption child of this component.
- Parameters:
caption- The caption child of the component.Default:
null.- Returns:
- A modified copy of the
thisobject
-
of
Returns the instance with the given label.- Parameters:
label- The label that the tab holds.
-
of
Returns the instance with the given label and image.- Parameters:
label- The label that the tab holds.image- The image that the tab holds.
-
ofImage
Returns the instance with the given image.- Parameters:
image- The image that the tab holds.
-
ofCaption
Returns the instance with the givenICaption.- Parameters:
caption- The caption container of this component.
-
ofId
Returns the instance with the given id.- Parameters:
id- The id to identify this component
-