|
JavaView® v2.12 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
|
+--java.awt.Component
|
+--java.awt.Container
|
+--java.awt.Panel
|
+--jv.object.PsPanel
|
+--jv.objectGui.PsTabPanel
Panel with header of tabs and a body panel with cardlayout.
Usage:
tabPanel = new PsTabPanel();
add(tabPanel); // add tabbed panel like any other panel
tabPanel.addPanel("Domain", m_domain.getInfoPanel());
tabPanel.addPanel("Surface", m_function.getInfoPanel());
tabPanel.setVisible("Surface"); // select initially active panel
tabPanel.validate(); // layout panel again
Use the following call to reset the tabbed panel, i.e. remove all panels.
tabPanel.init();
// add some new stuff to panel
tabPanel.validate(); // layout panel again
Panels added to PsTabPanel must be instance of PsPanel to ensure an update()
method to be called whenever the panel becomes visible.
| Fields inherited from class jv.object.PsPanel |
BORDER_GROOVE, BORDER_LINE, BORDER_NONE, BORDER_SUNK |
| Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
PsTabPanel()
|
|
| Method Summary | |
void |
addPanel(java.lang.String name,
PsPanel panel)
|
java.lang.String |
getCurrentPanel()
|
PsPanel |
getPanel(java.lang.String name)
|
boolean |
hasPanel(PsPanel panel)
|
boolean |
hasPanel(java.lang.String name)
|
void |
init()
|
void |
removePanel(java.lang.String name)
|
void |
setVisible(java.lang.String name)
Switch to panel with given name. |
void |
validate()
Validate card panel and show named panel. |
| Methods inherited from class jv.object.PsPanel |
addLabelComponent, addLine, addSubTitle, addTextField, addTitle, drawBorder, drawBorder, drawText, getFather, getInsets, getLanguage, getTitle, hasTitle, instanceOf, paint, setBorderType, setImage, setInsetSize, setOutOfDate, setParent, setTitle, setVisible, update, update |
| Methods inherited from class java.awt.Panel |
addNotify, getAccessibleContext |
| Methods inherited from class java.awt.Container |
add, add, add, add, add, addContainerListener, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getLayout, getListeners, getMaximumSize, getMinimumSize, getPreferredSize, insets, invalidate, isAncestorOf, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, remove, remove, removeAll, removeContainerListener, removeNotify, setFont, setLayout |
| Methods inherited from class java.awt.Component |
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addPropertyChangeListener, addPropertyChangeListener, bounds, checkImage, checkImage, contains, contains, createImage, createImage, disable, dispatchEvent, enable, enable, enableInputMethods, getBackground, getBounds, getBounds, getColorModel, getComponentOrientation, getCursor, getDropTarget, getFont, getFontMetrics, getForeground, getGraphics, getGraphicsConfiguration, getHeight, getInputContext, getInputMethodRequests, getLocale, getLocation, getLocation, getLocationOnScreen, getName, getParent, getPeer, getSize, getSize, getToolkit, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isDisplayable, isDoubleBuffered, isEnabled, isFocusTraversable, isLightweight, isOpaque, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, printAll, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, reshape, resize, resize, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setForeground, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface jv.object.PsUpdateIf |
getName |
| Constructor Detail |
public PsTabPanel()
| Method Detail |
public void init()
init in class PsPanel
public void addPanel(java.lang.String name,
PsPanel panel)
public java.lang.String getCurrentPanel()
public PsPanel getPanel(java.lang.String name)
public boolean hasPanel(java.lang.String name)
public boolean hasPanel(PsPanel panel)
public void validate()
validate in class java.awt.Containerpublic void removePanel(java.lang.String name)
public void setVisible(java.lang.String name)
|
JavaView® v2.12 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||