All Packages  Class Hierarchy  This Package  Previous  Next  Index

Interface jclass.bwt.JCOutlinerInterface

public interface JCOutlinerInterface
extends JCMultiColumnInterface, JCItemSelectable
An interface which defines the API for components which have an outliner-like behavior.

See Also:
JCOutliner

Method Index

 o calculateNodeHeight(JCOutlinerNode)
Calculates the height of a node (by looking at the node's style).
 o eventInShortcut(Event, JCOutlinerNode)
Returns true if the node is a folder and the event is within the folder's shortcut button.
 o eventToNode(Event)
Gets the node in which the event occurred.
 o folderChanged(JCOutlinerNode)
Notifies the outliner that the number of a folder's children has changed.
 o getAutoSelect()
Gets the AutoSelect value.
 o getBounds(JCOutlinerNode, Rectangle)
Gets the physical bounding rectangle of a node (icon and label) (adjusted for scrolling and insets).
 o getDefaultNodeStyle()
Gets the default node style.
 o getFocusNode()
Returns the node which currently has focus, or null.
 o getNextNode(JCOutlinerNode)
Returns the next visible node, or null if none was found.
 o getNodeHeight()
Gets the NodeHeight value.
 o getNodeIndent()
Gets the NodeIndent value.
 o getNumNodes()
Gets the current number of non-collapsed nodes (the number of open folders and their children).
 o getPreviousNode(JCOutlinerNode)
Returns the previous visible node, or null if none was found.
 o getRootNode()
Gets the root node.
 o getRootVisible()
Gets the RootVisible value.
 o getSelectedNode()
Returns the currently selected node, or null.
 o getSpacing()
Gets the spacing between items.
 o getStateList()
Gets the current StateList.
 o getStyleList()
Gets the current StyleList.
 o getVisibleNodes()
Gets a list of the nodes which are currently displayed.
 o getVisibleRows()
Returns the number of visible lines.
 o makeNodeVisible(JCOutlinerNode)
Scrolls the display if necessary to make the node visible.
 o selectNode(JCOutlinerNode, Event)
Selects a node, and posts a JCOutlinerEvent.
 o setAutoSelect(boolean)
If true, the node which currently has focus is also selected.
 o setFocusNode(JCOutlinerNode, Event)
Sets a node to have the keyboard focus.
 o setNodeHeight(int)
Sets the height of each node (pixels).
 o setNodeIndent(int)
Sets the indentation of each node relative to its parent (pixels).
 o setNodeState(JCOutlinerNode, int, boolean)
Sets the state of a folder.
 o setRootNode(JCOutlinerNode)
Sets the root node.
 o setRootVisible(boolean)
If true, the root node is drawn.
 o setSpacing(int)
Sets the spacing between items (default: 0).
 o setStateList(int[])
Sets a list of values used for double-clicking on a folder or clicking its shortcut button.
 o setStyleList(JCOutlinerNodeStyle[])
Sets the list of node styles.
 o setVisibleRows(int)
Sets the number of visible rows.

Methods

 o folderChanged
 public abstract void folderChanged(JCOutlinerNode node)
Notifies the outliner that the number of a folder's children has changed.

 o getRootNode
 public abstract JCOutlinerNode getRootNode()
Gets the root node.

See Also:
setRootNode
 o setRootNode
 public abstract void setRootNode(JCOutlinerNode node)
Sets the root node.

 o getRootVisible
 public abstract boolean getRootVisible()
Gets the RootVisible value.

See Also:
setRootVisible
 o setRootVisible
 public abstract void setRootVisible(boolean v)
If true, the root node is drawn.

 o calculateNodeHeight
 public abstract int calculateNodeHeight(JCOutlinerNode node)
Calculates the height of a node (by looking at the node's style).

 o getNodeHeight
 public abstract int getNodeHeight()
Gets the NodeHeight value.

See Also:
setNodeHeight
 o setNodeHeight
 public abstract void setNodeHeight(int v)
Sets the height of each node (pixels). If 0, the height is determined using the largest font and image height in the list of node styles.

 o getAutoSelect
 public abstract boolean getAutoSelect()
Gets the AutoSelect value.

See Also:
setAutoSelect
 o setAutoSelect
 public abstract void setAutoSelect(boolean v)
If true, the node which currently has focus is also selected.

See Also:
setFocusNode, selectNode
 o getNodeIndent
 public abstract int getNodeIndent()
Gets the NodeIndent value.

See Also:
setNodeIndent
 o setNodeIndent
 public abstract void setNodeIndent(int v)
Sets the indentation of each node relative to its parent (pixels).

 o getStateList
 public abstract int[] getStateList()
Gets the current StateList.

See Also:
setStateList
 o setStateList
 public abstract void setStateList(int list[])
Sets a list of values used for double-clicking on a folder or clicking its shortcut button. The folder's state is cycled through the list. Valid values:
BWTEnum.FOLDER_CLOSED		Folder closed; no children visible
BWTEnum.FOLDER_OPEN_NONE	Folder open; no children visible
BWTEnum.FOLDER_OPEN_FOLDERS	Folder open; only folder children visible
BWTEnum.FOLDER_OPEN_ITEMS	Folder open; only non-folder children visible
BWTEnum.FOLDER_OPEN_ALL		Folder open; all children visible
 

 o getStyleList
 public abstract JCOutlinerNodeStyle[] getStyleList()
Gets the current StyleList.

See Also:
setStyleList
 o setStyleList
 public abstract void setStyleList(JCOutlinerNodeStyle list[])
Sets the list of node styles. The list is only used for determining the node height if it has not been set.

See Also:
setNodeHeight
 o getDefaultNodeStyle
 public abstract JCOutlinerNodeStyle getDefaultNodeStyle()
Gets the default node style.

 o getSpacing
 public abstract int getSpacing()
Gets the spacing between items.

See Also:
setSpacing
 o setSpacing
 public abstract void setSpacing(int v)
Sets the spacing between items (default: 0). This value increases the HighlightThickness value.

See Also:
setHighlightThickness
 o getVisibleRows
 public abstract int getVisibleRows()
Returns the number of visible lines.

See Also:
setVisibleRows
 o setVisibleRows
 public abstract void setVisibleRows(int v)
Sets the number of visible rows. If set to 0 (default), the list will attempt to resize itself so that all its items are visible.

 o getSelectedNode
 public abstract JCOutlinerNode getSelectedNode()
Returns the currently selected node, or null.

 o selectNode
 public abstract void selectNode(JCOutlinerNode node,
                                 Event ev)
Selects a node, and posts a JCOutlinerEvent.

Parameters:
node - if null, the currently selected node is deselected
ev - event which caused the selection
 o getFocusNode
 public abstract JCOutlinerNode getFocusNode()
Returns the node which currently has focus, or null.

 o setFocusNode
 public abstract void setFocusNode(JCOutlinerNode node,
                                   Event ev)
Sets a node to have the keyboard focus.

Parameters:
node - if null, no the current focus node is unchanged
ev - event which caused the focus change
 o getVisibleNodes
 public abstract JCVector getVisibleNodes()
Gets a list of the nodes which are currently displayed.

 o setNodeState
 public abstract boolean setNodeState(JCOutlinerNode node,
                                      int state,
                                      boolean notify)
Sets the state of a folder.

Parameters:
node - if not a folder, no action is taken
state - one of:
BWTEnum.FOLDER_CLOSED        Folder closed; no children visible
BWTEnum.FOLDER_OPEN_NONE     Folder open; no children visible
BWTEnum.FOLDER_OPEN_FOLDERS  Folder open; only folder children visible
BWTEnum.FOLDER_OPEN_ITEMS    Folder open; only non-folder children visible
BWTEnum.FOLDER_OPEN_ALL 	 Folder open; all children visible
 
notify - if true, a JCOutlinerEvent is posted for the node
Returns:
false if the app disallowed the state change
 o makeNodeVisible
 public abstract boolean makeNodeVisible(JCOutlinerNode node)
Scrolls the display if necessary to make the node visible.

Returns:
false if the node could not be made visible due to its parents state
 o getNumNodes
 public abstract int getNumNodes()
Gets the current number of non-collapsed nodes (the number of open folders and their children).

 o getNextNode
 public abstract JCOutlinerNode getNextNode(JCOutlinerNode node)
Returns the next visible node, or null if none was found.

 o getPreviousNode
 public abstract JCOutlinerNode getPreviousNode(JCOutlinerNode node)
Returns the previous visible node, or null if none was found.

 o getBounds
 public abstract Rectangle getBounds(JCOutlinerNode node,
                                     Rectangle rect)
Gets the physical bounding rectangle of a node (icon and label) (adjusted for scrolling and insets).

Parameters:
rect - if not null, its members are set
Returns:
null if rect is null, otherwise the bounding rectangle
 o eventToNode
 public abstract JCOutlinerNode eventToNode(Event ev)
Gets the node in which the event occurred.

 o eventInShortcut
 public abstract boolean eventInShortcut(Event ev,
                                         JCOutlinerNode node)
Returns true if the node is a folder and the event is within the folder's shortcut button.


All Packages  Class Hierarchy  This Package  Previous  Next  Index