content
The HTML for the contents of the tabs.
Serializable
, DynamicAttributes
, IterationTag
, JspTag
, Tag
, DynamicActionAttributes
, Renderer<TabAction>
public class TabControl extends StylableTag implements Renderer<TabAction>
Tab
tags to define each tab inside the
tabcontrol.
Syntax:
<t:tabcontrol id=... clazz=... subclass=... style=... contentstyle=... active=... position=... notabs=true|false extensions=... >
Attribute | Default value | Required | Description |
id | - | yes | The ID of the tab control. The value of this attribute
goes directly into the standard id attribute.
This means that if you need a reference to the tab control object in your own
JavaScript code, you may for example use the following code:
|
clazz | tabcontrol | no |
The value if this attribute goes directly into the standard HTML
class attribute. This allows you to apply different styles
to different tables.
|
subclass | - | no | Additional classes to put in the HTML class attribute. Doesn't replace the main class attribute. |
style | - | no |
The value if this attribute goes directly into the standard HTML
style attribute. This allows you to apply different styles
to different tabcontrols.
|
contentstyle | - | no |
The value if this attribute goes directly into the standard HTML
style attribute for the content section. This allows you to apply
different styles to different tabcontrols.
|
active | - | no | The id of the tab that should be active to begin with. If no value is specified the first tab is automatically made active. |
position | top | no | The position of the tabs in relation to the content. The default value is to display
the tabs at the top. The only other allowed value is bottom .
|
notabs | false | no | If the tabcontrol should display tabs or not. If false the tab control will not output any HTML except the contents of the active tab. |
extensions | - | no |
An ExtensionsInvoker for TabAction extensions. All
actions will be rendered by this tabcontrol after all the
normally defined tags have been rendered. Since BASE 2.17.
|
Tab
,
Serialized FormModifier and Type | Field | Description |
---|---|---|
private String |
active |
The ID attribute of the active tab.
|
static int |
BOTTOM |
Tabs are at the bottom of the tab control.
|
private StringBuilder |
content |
The HTML for the contents of the tabs.
|
private String |
contentStyle |
Optional
style attribute for the content section |
private ExtensionsInvoker<TabAction> |
extensions |
|
private String |
initialTab |
The ID of the tab that is initially active.
|
private boolean |
noTabs |
If the tabs should be displayed or not.
|
private int |
numTabs |
The number of tabs.
|
private int |
position |
The position of the tabs.
|
private boolean |
remember |
If it should try to remember the last active tab on the page
|
private static long |
serialVersionUID |
|
private StringBuilder |
tabs |
The HTML for the tabs.
|
static int |
TOP |
Tabs are at the top of the tab control.
|
id, pageContext
EVAL_BODY_AGAIN
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE
Constructor | Description |
---|---|
TabControl() |
Modifier and Type | Method | Description |
---|---|---|
(package private) void |
addTab(TabAction tab) |
|
int |
doEndTag() |
|
int |
doStartTag() |
|
String |
getActive() |
|
String |
getContentstyle() |
|
void |
render(TabAction action) |
Render the action in the client application.
|
void |
setActive(String active) |
|
void |
setContentstyle(String contentStyle) |
|
void |
setExtensions(ExtensionsInvoker<TabAction> extensions) |
|
void |
setNotabs(boolean noTabs) |
|
void |
setPosition(String position) |
|
void |
setRemember(boolean remember) |
addDynamicAttributes, addIdAndStyles, getClazz, getDynamicActionAttributes, getDynamicAttribute, getFullClass, getIdPrefix, getStyle, getSubclass, initDefaultAttributes, setClazz, setDynamicAttribute, setMoreDynamicAttributes, setPageContext, setStyle, setSubclass
doAfterBody, findAncestorWithClass, getId, getParent, getValue, getValues, release, removeValue, setId, setParent, setValue
style
attribute for the content sectiondoStartTag
in interface Tag
doStartTag
in class TagSupport
JspException
doEndTag
in interface Tag
doEndTag
in class TagSupport
JspException
Renderer