#include <outline.h>
Inheritance diagram for TOutline::
Public Methods | |
TOutline (const TRect &bounds, TScrollBar *aHScrollBar, TScrollBar *aVScrollBar, TNode *aRoot) | |
~TOutline () | |
virtual void | adjust (TNode *node, Boolean expand) |
virtual TNode* | getRoot () |
virtual int | getNumChildren (TNode *node) |
virtual TNode* | getChild (TNode *node, int i) |
virtual char* | getText (TNode *node) |
virtual Boolean | isExpanded (TNode *node) |
virtual Boolean | hasChildren (TNode *node) |
Static Public Methods | |
TStreamable* | build () |
Public Attributes | |
TNode* | root |
Static Public Attributes | |
const char* const | name |
Protected Methods | |
virtual void | write (opstream &os) |
virtual void* | read (ipstream &is) |
virtual void | writeNode (TNode *, opstream &) |
virtual TNode* | readNode (ipstream &) |
TOutline (StreamableInit) |
It assumes that the outline is a linked list of records of type TNode, so each node consists of a text string (TNode::text), a pointer to any child nodes (TNode::childList), and a pointer to the next node at the same level (TNode::next).
Definition at line 392 of file outline.h.
|
Constructs an outline view by passing `bounds', `aHScrollBar' and `aVScrollBar' to the constructor inherited from TOutlineViewer. Sets root to `aRoot', then calls update() to set the scrolling limits of the view based on the data in the outline. |
|
Disposes of the outline view by first disposing of the root node, which recursively disposes of all child nodes, then calling the destructor inherited from TView. |
|
Each streamable class needs a "builder" to allocate the correct memory for its objects together with the initialized virtual table pointers. This is achieved by calling this constructor with an argument of type StreamableInit. |
|
Sets the expanded field of `node' to the value passed in `expand'. If `expand' is True, this causes the child nodes linked to `node' to be displayed. If `expand' is False, node's child nodes are hidden. Reimplemented from TOutlineViewer. |
|
Called to create an object in certain stream-reading situations. Reimplemented from TOutlineViewer. |
|
Returns a pointer to the i-th child in node's TNode::childList. Reimplemented from TOutlineViewer. |
|
Returns the number of nodes in node's TNode::childList, or zero if TNode::childList is 0. Reimplemented from TOutlineViewer. |
|
Returns root, which points to the top of the list of nodes for the outline. Reimplemented from TOutlineViewer. |
|
Returns the string pointed to by node's TNode::text field. Reimplemented from TOutlineViewer. |
|
Returns True if node's TNode::childList is non-0; otherwise returns False. Reimplemented from TOutlineViewer. |
|
Returns the value of node's TNode::expanded field. Reimplemented from TOutlineViewer. |
|
Reads from the input stream `is'. Reimplemented from TOutlineViewer. |
|
Undocumented. |
|
Writes to the output stream `os'. Reimplemented from TOutlineViewer. |
|
Undocumented. |
|
Undocumented. Reimplemented from TOutlineViewer. |
|
Points to the root node of the outline tree. |