com.sibvisions.rad.ui.swing.impl.container
Class SwingSplitPanel

java.lang.Object
  extended by com.sibvisions.rad.ui.awt.impl.AwtResource<C>
      extended by com.sibvisions.rad.ui.awt.impl.AwtComponent<C>
          extended by com.sibvisions.rad.ui.awt.impl.AwtContainer<C>
              extended by com.sibvisions.rad.ui.swing.impl.SwingComponent<JVxSplitPane>
                  extended by com.sibvisions.rad.ui.swing.impl.container.SwingSplitPanel
All Implemented Interfaces:
ComponentListener, KeyListener, MouseListener, EventListener, ISplitPanel, IAlignmentConstants, IComponent, IContainer, IResource, INamedObject

public class SwingSplitPanel
extends SwingComponent<JVxSplitPane>
implements ISplitPanel

The SwingSplitPanel is the ISplitPanel implementation for swing.

See Also:
JSplitPane, ISplitPanel

Field Summary
 
Fields inherited from class com.sibvisions.rad.ui.awt.impl.AwtComponent
eventComponentMoved, eventComponentResized, eventSource, factory, parent
 
Fields inherited from class com.sibvisions.rad.ui.awt.impl.AwtResource
resource
 
Fields inherited from interface javax.rad.ui.container.ISplitPanel
DIVIDER_BOTTOM_RIGHT, DIVIDER_RELATIVE, DIVIDER_TOP_LEFT, FIRST_COMPONENT, SECOND_COMPONENT, SPLIT_LEFT_RIGHT, SPLIT_TOP_BOTTOM
 
Fields inherited from interface javax.rad.ui.IAlignmentConstants
ALIGN_BOTTOM, ALIGN_CENTER, ALIGN_LEFT, ALIGN_RIGHT, ALIGN_STRETCH, ALIGN_TOP
 
Constructor Summary
SwingSplitPanel()
          Creates a new instance of SwingLabel with a divider size of 6, continous layout enabled and one touch expandable enabled.
 
Method Summary
 void add(IComponent pComponent, Object pConstraints, int pIndex)
          Adds the specified IComponent to this container with the specified constraints at the specified index.
 int getDividerAlignment()
          Gets the divider alignment.
 int getDividerPosition()
          Gets the position of the divider.
 IComponent getFirstComponent()
          Returns the component to the left (or above) the divider.
 int getOrientation()
          Returns the orientation.
 IComponent getSecondComponent()
          Returns the component to the right (or below) the divider.
 void remove(int pIndex)
          Removes the IComponent, specified by index, from this container.
 void setDividerAlignment(int pDividerAlignment)
          Sets the divider alignment.
 void setDividerPosition(int pDividerPosition)
          Sets the position of the divider.
 void setFirstComponent(IComponent pComponent)
          Sets the component to the left (or above) the divider.
 void setOrientation(int pOrientation)
          Sets the orientation, or how the splitter is divided.
 void setSecondComponent(IComponent pComponent)
          Sets the component to the right (or below) the divider.
 
Methods inherited from class com.sibvisions.rad.ui.swing.impl.SwingComponent
capture, getToolTipText, setBackground, setToolTipText
 
Methods inherited from class com.sibvisions.rad.ui.awt.impl.AwtContainer
add, add, add, addIntern, checkAdd, getComponent, getComponentCount, getLayout, indexOf, remove, removeAll, removeIntern, setLayout, setLayoutIntern
 
Methods inherited from class com.sibvisions.rad.ui.awt.impl.AwtComponent
componentHidden, componentMoved, componentResized, componentShown, createImage, eventComponentMoved, eventComponentResized, eventKeyPressed, eventKeyReleased, eventKeyTyped, eventMouseClicked, eventMouseEntered, eventMouseExited, eventMousePressed, eventMouseReleased, getBackground, getBounds, getCursor, getEventSource, getFactory, getFont, getForeground, getHorizontalAlignment, getLocation, getLocationRelativeTo, getMaximumSize, getMinimumSize, getName, getParent, getPreferredSize, getSize, getVerticalAlignment, isBackgroundSet, isCursorSet, isEnabled, isFocusable, isFontSet, isForegroundSet, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isVisible, keyPressed, keyReleased, keyTyped, mouseClicked, mouseEntered, mouseExited, mousePressed, mouseReleased, requestFocus, setBounds, setCursor, setEnabled, setEventSource, setFactory, setFocusable, setFont, setForeground, setHorizontalAlignment, setLocation, setLocationRelativeTo, setMaximumSize, setMinimumSize, setName, setParent, setPreferredSize, setSize, setVerticalAlignment, setVisible, validate
 
Methods inherited from class com.sibvisions.rad.ui.awt.impl.AwtResource
equals, getResource, hashCode, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface javax.rad.ui.IContainer
add, add, add, getComponent, getComponentCount, getLayout, indexOf, remove, removeAll, setLayout
 
Methods inherited from interface javax.rad.ui.IComponent
capture, eventComponentMoved, eventComponentResized, eventKeyPressed, eventKeyReleased, eventKeyTyped, eventMouseClicked, eventMouseEntered, eventMouseExited, eventMousePressed, eventMouseReleased, getBackground, getBounds, getCursor, getEventSource, getFactory, getFont, getForeground, getLocation, getLocationRelativeTo, getMaximumSize, getMinimumSize, getName, getParent, getPreferredSize, getSize, getToolTipText, isBackgroundSet, isCursorSet, isEnabled, isFocusable, isFontSet, isForegroundSet, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isVisible, requestFocus, setBackground, setBounds, setCursor, setEnabled, setEventSource, setFocusable, setFont, setForeground, setLocation, setLocationRelativeTo, setMaximumSize, setMinimumSize, setName, setParent, setPreferredSize, setSize, setToolTipText, setVisible
 
Methods inherited from interface javax.rad.ui.IResource
getResource
 

Constructor Detail

SwingSplitPanel

public SwingSplitPanel()
Creates a new instance of SwingLabel with a divider size of 6, continous layout enabled and one touch expandable enabled.

Method Detail

getOrientation

public int getOrientation()
Returns the orientation.

Specified by:
getOrientation in interface ISplitPanel
Returns:
an integer giving the orientation
See Also:
ISplitPanel.setOrientation(int)

setOrientation

public void setOrientation(int pOrientation)
Sets the orientation, or how the splitter is divided. The options are:

Specified by:
setOrientation in interface ISplitPanel
Parameters:
pOrientation - an integer specifying the orientation

getFirstComponent

public IComponent getFirstComponent()
Returns the component to the left (or above) the divider.

Specified by:
getFirstComponent in interface ISplitPanel
Returns:
the IComponent displayed in that position

setFirstComponent

public void setFirstComponent(IComponent pComponent)
Sets the component to the left (or above) the divider.

Specified by:
setFirstComponent in interface ISplitPanel
Parameters:
pComponent - the IComponent to display in that position

getSecondComponent

public IComponent getSecondComponent()
Returns the component to the right (or below) the divider.

Specified by:
getSecondComponent in interface ISplitPanel
Returns:
the Component displayed in that position

setSecondComponent

public void setSecondComponent(IComponent pComponent)
Sets the component to the right (or below) the divider.

Specified by:
setSecondComponent in interface ISplitPanel
Parameters:
pComponent - the IComponent to display in that position

getDividerPosition

public int getDividerPosition()
Gets the position of the divider.

Specified by:
getDividerPosition in interface ISplitPanel
Returns:
the position of the divider.

setDividerPosition

public void setDividerPosition(int pDividerPosition)
Sets the position of the divider.

Specified by:
setDividerPosition in interface ISplitPanel
Parameters:
pDividerPosition - the position of the divider.

getDividerAlignment

public int getDividerAlignment()
Gets the divider alignment.

Specified by:
getDividerAlignment in interface ISplitPanel
Returns:
the divider alignment: ISplitPanel.DIVIDER_TOP_LEFT, ISplitPanel.DIVIDER_BOTTOM_RIGHT, ISplitPanel.DIVIDER_RELATIVE

setDividerAlignment

public void setDividerAlignment(int pDividerAlignment)
Sets the divider alignment.

Specified by:
setDividerAlignment in interface ISplitPanel
Parameters:
pDividerAlignment - the divider alignment: ISplitPanel.DIVIDER_TOP_LEFT, ISplitPanel.DIVIDER_BOTTOM_RIGHT, ISplitPanel.DIVIDER_RELATIVE

add

public void add(IComponent pComponent,
                Object pConstraints,
                int pIndex)
Adds the specified IComponent to this container with the specified constraints at the specified index. Also notifies the layout manager to add the component to the this container's layout using the specified constraints object.

Specified by:
add in interface IContainer
Overrides:
add in class AwtContainer<JVxSplitPane>
Parameters:
pComponent - the IComponent to be added
pConstraints - an object expressing layout contraints for this
pIndex - the position in the container's list at which to insert the IComponent; -1 means insert at the end component
See Also:
IComponent

remove

public void remove(int pIndex)
Removes the IComponent, specified by index, from this container. This method also notifies the layout manager to remove the component from this container's layout via the removeLayoutComponent method.

Specified by:
remove in interface IContainer
Overrides:
remove in class AwtContainer<JVxSplitPane>
Parameters:
pIndex - the index of the IComponent to be removed
See Also:
IContainer.add(javax.rad.ui.IComponent), IContainer.getComponentCount()


Copyright © 2009 SIB Visions GmbH. All Rights Reserved.