|
EchoPoint 2.1.0rc5 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnextapp.echo2.app.Component
echopointng.ComponentEx
echopointng.AbleComponent
echopointng.TabbedPane
public class TabbedPane
TabbedPane is used to provide a tabbed interface to a
collection of Components.
A TabModel is used to provide the collections of tabs and the
content that should be shown when a given tab is selected.
A SingleSelectionModel is used to track which tab is currently
selected.
This component is a PaneContainer and hence can have
components that implement Pane as a child. However many
Panes, such as SplitPane, require a definite
height to be set in order to work properly. So make sure you call setHeight()
if one of the children implements Pane
| Field Summary | |
|---|---|
static Style |
DEFAULT_STYLE
|
static String |
PROPERTY_MODEL
|
static String |
PROPERTY_SELECTION_MODEL
|
static String |
PROPERTY_TAB_BORDER_STYLE
|
static String |
PROPERTY_TAB_LEAD_IN_WIDTH
|
static String |
PROPERTY_TAB_PLACEMENT
|
static String |
PROPERTY_TAB_SPACING
|
static int |
TAB_LINE_AND_CONTENT
TAB_LINE_AND_CONTENT - shows a border around the tabs and a line betweent the tabs and the content It looks a bit like this (where ==== is the border and --- is the non-border area ----------- ----------- ----------- ----------- - - - - - - - - - - - - - - - - ============================ ========================== = = = = = = = = = = = = =============================================================== |
static int |
TAB_LINE_ONLY
TAB_LINE_ONLY - shows no border around the tabs and a line betweent the tabs and the content It looks a bit like this (where ==== is the border and --- is the non-border area ----------- ----------- ----------- ----------- - - - - - - - - - - - - - - - - ============================ ========================== - - - - - - - - - - - - --------------------------------------------------------------- |
static int |
TAB_STRIP_AND_CONTENT
TAB_STRIP_AND_CONTENT - shows the border around the tabs and content It looks a bit like this (where ==== is the border and --- is the non-border area =========== =========== =========== =========== = = = = = = = = = = = = = = = = ============================ ========================== = = = = = = = = = = = = =============================================================== |
static int |
TAB_STRIP_ONLY
TAB_STRIP_ONLY - shows a border around the tabs and a line betweent the tabs and the content It looks a bit like this (where ==== is the border and --- is the non-border area =========== =========== =========== =========== = = = = = = = = = = = = = = = = ============================ ========================== - - - - - - - - - - - - --------------------------------------------------------------- |
| Fields inherited from class echopointng.ComponentEx |
|---|
PROPERTY_HIDDEN |
| Fields inherited from interface echopointng.able.Stretchable |
|---|
PROPERTY_HEIGHT_STRETCHED, PROPERTY_MAXIMUM_STRETCHED_HEIGHT, PROPERTY_MINIMUM_STRETCHED_HEIGHT |
| Fields inherited from interface echopointng.able.Scrollable |
|---|
ALWAYS, AUTO, CLIPHIDE, NEVER, PROPERTY_SCROLL_BAR_BASE_COLOR, PROPERTY_SCROLL_BAR_POLICY, PROPERTY_SCROLL_BAR_PROPERTIES, UNDEFINED |
| Fields inherited from interface echopointng.able.Widthable |
|---|
PROPERTY_WIDTH |
| Fields inherited from interface echopointng.able.Heightable |
|---|
PROPERTY_HEIGHT |
| Fields inherited from interface echopointng.able.AccessKeyable |
|---|
PROPERTY_ACCESS_KEY |
| Fields inherited from interface echopointng.able.Borderable |
|---|
PROPERTY_BORDER |
| Fields inherited from interface echopointng.able.MouseCursorable |
|---|
CURSOR_AUTO, CURSOR_CROSSHAIR, CURSOR_CUSTOM_URI, CURSOR_DEFAULT, CURSOR_E_RESIZE, CURSOR_HELP, CURSOR_MOVE, CURSOR_N_RESIZE, CURSOR_NE_RESIZE, CURSOR_NW_RESIZE, CURSOR_POINTER, CURSOR_S_RESIZE, CURSOR_SE_RESIZE, CURSOR_SW_RESIZE, CURSOR_TEXT, CURSOR_W_RESIZE, CURSOR_WAIT, PROPERTY_MOUSE_CURSOR, PROPERTY_MOUSE_CURSOR_URI |
| Fields inherited from interface echopointng.able.Insetable |
|---|
DEFAULT_INSETS, DEFAULT_OUTSETS, PROPERTY_INSETS, PROPERTY_OUTSETS |
| Fields inherited from interface echopointng.able.ToolTipable |
|---|
PROPERTY_TOOL_TIP_TEXT |
| Constructor Summary | |
|---|---|
TabbedPane()
Constructs a TabbedPane with the a default empty
DefaultTabModel as the TabbedPane's model. |
|
TabbedPane(TabModel tabModel)
Constructs a TabbedPane with the specified
TabModel. |
|
| Method Summary | |
|---|---|
Extent |
getMaximumStretchedHeight()
|
Extent |
getMinimumStretchedHeight()
|
TabModel |
getModel()
|
Color |
getScrollBarBaseColor()
Returns the base color of the ScrollBarProperties associated with this Scrollable |
int |
getScrollBarPolicy()
Returns the ScrollBarPolicy in place This can be one of : NONE ALWAYS AUTO CLIPHIDE |
ScrollBarProperties |
getScrollBarProperties()
Returns the ScrollBarProperties associated with this Scrollable |
int |
getSelectedIndex()
|
SingleSelectionModel |
getSelectionModel()
|
int |
getTabBorderStyle()
This can be one of the following values : TAB_STRIP_ONLY - shows a border around the tabs and a line betweent the tabs and the content TAB_STRIP_AND_CONTENT - shows the border around the tabs and content TAB_LINE_ONLY - shows no border around the tabs and a line betweent the tabs and the content TAB_LINE_AND_CONTENT - shows a border around the tabs and a line betweent the tabs and the content |
Extent |
getTabLeadInWidth()
|
int |
getTabPlacement()
Returns where the tabs are placed on the TabbedPane. |
int |
getTabSpacing()
|
boolean |
isHeightStretched()
|
void |
processInput(String inputName,
Object inputValue)
|
void |
setHeightStretched(boolean newValue)
Set to true if the height should be stretched to use all available space of its parent. |
void |
setMaximumStretchedHeight(Extent newValue)
Sets the maximum height that the component should stretch itself up to in pixels. |
void |
setMinimumStretchedHeight(Extent newValue)
Sets the minimum height that the component should stretch itself down to in pixels. |
void |
setModel(TabModel model)
Sets the TabModel used to provide the TabbedPane's tabs
and content. |
void |
setScrollBarBaseColor(Color newValue)
Sets the base color of the ScrollBarProperties associated with this Scrollable. |
void |
setScrollBarPolicy(int newScrollBarPolicy)
Sets the scroll bar policy of the component This can be one of : SCOLLBARS_NONE SCOLLBARS_ALWAYS SCOLLBARS_AUTO CLIPHIDE |
void |
setScrollBarProperties(ScrollBarProperties newValue)
Sets the ScrollBarProperties associated with this Scrollable |
void |
setSelectedIndex(int index)
Sets the selected index of the TabbedPane. |
void |
setSelectionModel(SingleSelectionModel selectionModel)
Sets the SingleSelectionModel used to track the selected
index of the TabbedPane |
void |
setTabBorderStyle(int newValue)
Sets the tab border style to use. |
void |
setTabLeadInWidth(Extent newValue)
Sets the width of a lead in region before the first tab placement |
void |
setTabPlacement(int tabPlacement)
Sets where the tabs are placed on the TabbedPane. |
void |
setTabSpacing(int tabSpacing)
Sets the spacing (in pixels) between tabs |
int |
size()
|
void |
validate()
|
| Methods inherited from class echopointng.AbleComponent |
|---|
getAccessKey, getBorder, getHeight, getInsets, getMouseCursor, getMouseCursorUri, getOutsets, getToolTipText, getWidth, setAccessKey, setBorder, setHeight, setInsets, setMouseCursor, setMouseCursorUri, setOutsets, setToolTipText, setWidth |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface echopointng.able.Delegateable |
|---|
getRenderProperty, getRenderProperty |
| Methods inherited from interface echopointng.able.Widthable |
|---|
getWidth, setWidth |
| Methods inherited from interface echopointng.able.Delegateable |
|---|
getRenderProperty, getRenderProperty |
| Methods inherited from interface echopointng.able.Heightable |
|---|
getHeight, setHeight |
| Methods inherited from interface echopointng.able.Delegateable |
|---|
getRenderProperty, getRenderProperty |
| Field Detail |
|---|
public static final Style DEFAULT_STYLE
public static final String PROPERTY_MODEL
public static final String PROPERTY_SELECTION_MODEL
public static final String PROPERTY_TAB_BORDER_STYLE
public static final String PROPERTY_TAB_LEAD_IN_WIDTH
public static final String PROPERTY_TAB_PLACEMENT
public static final String PROPERTY_TAB_SPACING
public static final int TAB_LINE_AND_CONTENT
It looks a bit like this (where ==== is the border and --- is the non-border area
----------- ----------- ----------- ----------- - - - - - - - - - - - - - - - - ============================ ========================== = = = = = = = = = = = = ===============================================================
public static final int TAB_LINE_ONLY
It looks a bit like this (where ==== is the border and --- is the non-border area
----------- ----------- ----------- ----------- - - - - - - - - - - - - - - - - ============================ ========================== - - - - - - - - - - - - ---------------------------------------------------------------
public static final int TAB_STRIP_AND_CONTENT
It looks a bit like this (where ==== is the border and --- is the non-border area
=========== =========== =========== =========== = = = = = = = = = = = = = = = = ============================ ========================== = = = = = = = = = = = = ===============================================================
public static final int TAB_STRIP_ONLY
It looks a bit like this (where ==== is the border and --- is the non-border area
=========== =========== =========== =========== = = = = = = = = = = = = = = = = ============================ ========================== - - - - - - - - - - - - ---------------------------------------------------------------
| Constructor Detail |
|---|
public TabbedPane()
TabbedPane with the a default empty
DefaultTabModel as the TabbedPane's model.
You can retrieve this as follows to add content to the TabbedPane:
TabbedPane tabbedPane = new TabbedPane();
DefaultTabModel model = (DefaultTabModel) tabbedPane.getModel();
model.addTab("Tab 1", new ContentThingy());
model.addTab("Tab 2", new ContentThingo());
public TabbedPane(TabModel tabModel)
TabbedPane with the specified
TabModel.
tabModel - -
the TabModel to use for this
TabbedPane| Method Detail |
|---|
public TabModel getModel()
TabModel used to provide the
TabbedPane's tabs and content.public int getSelectedIndex()
public SingleSelectionModel getSelectionModel()
SingleSelectionModel used to track the
selected index of the TabbedPanepublic int getTabBorderStyle()
public Extent getTabLeadInWidth()
public int getTabPlacement()
Alignment.TOP- the bottom of the TabbedPane
(default)Alignment.BOTTOM- the bottom of the TabbedPane
public int getTabSpacing()
public void processInput(String inputName,
Object inputValue)
processInput in class ComponentComponent.processInput(java.lang.String,
java.lang.Object)public void setModel(TabModel model)
TabModel used to provide the TabbedPane's tabs
and content.
model - -
the TabModel used to provide the TabbedPane's
tabs and content.public void setSelectedIndex(int index)
Shortcurt method to getSelectionModel().setSelectedIndex(index).
index - -
the index to selectpublic void setSelectionModel(SingleSelectionModel selectionModel)
SingleSelectionModel used to track the selected
index of the TabbedPane
selectionModel - -
the SingleSelectionModel used to track the
selected index of the TabbedPanepublic void setTabBorderStyle(int newValue)
newValue - TAB_STRIP_ONLY,
TAB_STRIP_AND_CONTENT,
TAB_LINE_ONLY,
TAB_LINE_AND_CONTENTpublic void setTabLeadInWidth(Extent newValue)
newValue - -
lead in region before the first tab placementpublic void setTabPlacement(int tabPlacement)
Alignment.TOP- the bottom of the TabbedPane
(default)Alignment.BOTTOM- the bottom of the TabbedPane
tabPlacement - public void setTabSpacing(int tabSpacing)
tabSpacing - -
the spacing (in pixels) between tabspublic int size()
TabModelpublic void validate()
validate in class ComponentComponent.validate()public Extent getMaximumStretchedHeight()
getMaximumStretchedHeight in interface StretchableStretchable.getMaximumStretchedHeight()public Extent getMinimumStretchedHeight()
getMinimumStretchedHeight in interface StretchableStretchable.getMinimumStretchedHeight()public boolean isHeightStretched()
isHeightStretched in interface StretchableStretchable.isHeightStretched()public void setHeightStretched(boolean newValue)
Stretchable
setHeightStretched in interface StretchablenewValue - -
a boolean flag indicating whether the height should be
stretched to use all available space of its parent or not.Stretchable.setHeightStretched(boolean)public void setMaximumStretchedHeight(Extent newValue)
Stretchable
setMaximumStretchedHeight in interface StretchablenewValue - -
a new Extent value that MUST be in pixel units.Stretchable.setMaximumStretchedHeight(nextapp.echo2.app.Extent)public void setMinimumStretchedHeight(Extent newValue)
Stretchable
setMinimumStretchedHeight in interface StretchablenewValue - -
a new Extent value that MUST be in pixel units.Stretchable.setMinimumStretchedHeight(nextapp.echo2.app.Extent)public Color getScrollBarBaseColor()
ScrollableScrollable
getScrollBarBaseColor in interface ScrollableScrollableScrollable.getScrollBarBaseColor()public int getScrollBarPolicy()
Scrollable
getScrollBarPolicy in interface ScrollableScrollable.getScrollBarPolicy()public ScrollBarProperties getScrollBarProperties()
ScrollableScrollable
getScrollBarProperties in interface ScrollableScrollableScrollable.getScrollBarProperties()public void setScrollBarBaseColor(Color newValue)
ScrollableScrollable.
If no ScrollBarProperties is available, then a new one should be created.
setScrollBarBaseColor in interface ScrollablenewValue - - the new base color of ScrollBarProperties to useScrollable.setScrollBarBaseColor(nextapp.echo2.app.Color)public void setScrollBarPolicy(int newScrollBarPolicy)
Scrollable
setScrollBarPolicy in interface ScrollableScrollable.setScrollBarPolicy(int)public void setScrollBarProperties(ScrollBarProperties newValue)
ScrollableScrollable
setScrollBarProperties in interface ScrollablenewValue - - the new ScrollBarProperties to useScrollable.setScrollBarProperties(echopointng.able.ScrollBarProperties)
|
EchoPoint 2.1.0rc5 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||