|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object charva.awt.Component charva.awt.Container charvax.swing.JTabbedPane
A component that lets the user display one of a set of components (usually Panels) at a time. The management of the tab-selection has to be performed outside of this component because it is possible that the currently selected tab does not contain any focusTraversable components. In this case, this JTabbedPane will never get the keyboard focus.
Field Summary |
Fields inherited from class charva.awt.Container |
_components, _currentFocus, _insets, _isValid, _layoutMgr, _minimumSize, _size |
Fields inherited from class charva.awt.Component |
_alignmentX, _alignmentY, _background, _cursesColor, _enabled, _focusListeners, _foreground, _keyListeners, _origin, _parent, _visible, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Constructor Summary | |
JTabbedPane()
Construct a JTabbedPane. |
Method Summary | |
void |
add(Component component_,
java.lang.Object constraints_)
Add the specified component to the tabbed pane. |
void |
addTab(java.lang.String title_,
java.lang.Object icon_,
Component component_,
java.lang.String keylabel_)
Add a new tab with the specified component, title and function-key. |
void |
debug(int level_)
|
void |
draw()
Draw all the components in this container. |
int |
getSelectedIndex()
|
Dimension |
getSize()
Override the method in Container. |
int |
getTabCount()
Returns the number of tabs in this tabbedpane. |
java.lang.String |
getTitleAt(int index)
Returns the title of the tab with the specified index. |
int |
indexOfTab(java.lang.String title)
Returns the first tab index with the specified title, or -1 if no tab has the title. |
boolean |
isEnabledAt(int index)
Returns true if the tab the index is enabled. |
Dimension |
minimumSize()
Override the method in Container. |
void |
remove(int index)
Removes the tab and component which corresponds to the specified index. |
void |
setEnabledAt(int index,
boolean enabled)
Make the tab at the specified index enabled. |
void |
setSelectedComponent(Component component_)
|
void |
setSelectedIndex(int index_)
|
void |
setTitleAt(int index,
java.lang.String title)
Sets the title of the tab with the specified index. |
Methods inherited from class charva.awt.Container |
add, doLayout, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getCurrentFocus, getHeight, getInsets, getWidth, invalidate, isFocusTraversable, isValid, nextFocus, previousFocus, processKeyEvent, remove, requestFocus, setBackground, setFocus, setForeground, setHeight, setLayout, setSize, setSize, setWidth, validate |
Methods inherited from class charva.awt.Component |
addFocusListener, addKeyListener, contains, contains, getAlignmentX, getAlignmentY, getAncestorWindow, getBackground, getBounds, getCursesColor, getForeground, getLocation, getLocationOnScreen, getName, getParent, hasFocus, hide, isDisplayed, isEnabled, isTotallyObscured, isVisible, processEvent, processFocusEvent, processMouseEvent, repaint, requestSync, setBounds, setBounds, setBounds, setEnabled, setLocation, setLocation, setName, setParent, setVisible, show, validateCursesColor |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public JTabbedPane()
Method Detail |
public void add(Component component_, java.lang.Object constraints_)
constraints
is a String, it will be used as the tab's
title; otherwise the component's name will be used as the title.
add
in class Container
public void addTab(java.lang.String title_, java.lang.Object icon_, Component component_, java.lang.String keylabel_)
title_
- The title of this tab.icon_
- An icon representing the component being added. This is
not used and is just for compatibility with Swing. Pass null for this
parameter.component_
- The component to be added in this tab.keylabel_
- A String representing the key that must be pressed to
select this tab.public void setSelectedIndex(int index_)
public int getSelectedIndex()
public void setSelectedComponent(Component component_)
public Dimension getSize()
getSize
in class Container
public Dimension minimumSize()
minimumSize
in class Container
public void draw()
Container
draw
in class Container
public void remove(int index)
public int indexOfTab(java.lang.String title)
public java.lang.String getTitleAt(int index)
public void setTitleAt(int index, java.lang.String title)
public void setEnabledAt(int index, boolean enabled)
public boolean isEnabledAt(int index)
public int getTabCount()
public void debug(int level_)
debug
in class Container
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |