PtGenTree

Gamma/Photon: Using Gamma™ with the Photon microGUIŽ, Version 4.0
Prev |  | Next

# `PtGenTree`

`PtGenTree` -- A parent class for tree widget resources.

## Synopsis

    class PtGenTree PtGenList
    {
        tree_flags;    // flag  (Pt_ARG_TREE_FLAGS)
    }

## Base Classes

`PtWidget` <-- `PtBasic` <-- `PtContainer` <-- `PtGenList` <-- `PtGenTree`

## Derived Classes

`PtFileSel`, `PtTree`

## Description

This class serves as a parent class of resources for tree widgets, and is not normally instantiated. Tree widgets are lists, each item of which can be expanded to display an attached sub-list, or collapsed to hide the sub-list. The items at the first level of the tree are called root items, and are always visible.

Trees can be built independently and added as roots or trees to the main tree. Items can be added separately as well, but this requires calls to `PtHold` and `PtUpdate` functions to avoid multiple redraws.

| For detailed information, please refer to PtGenTree in the Photon documentation.

## Instance Variables

tree_flags

  This instance variable controls the appearance and behavior of the tree, and may be a combination of zero or more of the following flags:

  Constant | Description
  --- | ---
  `Pt_TREE_HAS_BUTTONS` | Display the + and - buttons.
  `Pt_TREE_HAS_LINES` | Display connecting lines.
  `Pt_TREE_ROOT_LINES` | Display root lines and buttons, if any.
  `Pt_TREE_TO_RIGHT` | Items are extended to right edge.
  `Pt_TREE_TO_LEFT` | Background is extended to left edge.
  `Pt_TREE_COLLAPSING` | A subtype of `Pt_CB_TREE_STATE`, indicating a collapsing state.
  `Pt_TREE_EXPANDING` | A subtype of `Pt_CB_TREE_STATE`, indicating an expanding state.
  `Pt_TREE_ITEM_EXPANDABLE` | The item can be expanded.
  `Pt_TREE_ITEM_EXPANDED` | The item branches are expanded and displayed.

## Callbacks

The following callback is associated with this widget:

Callback | Description
--- | ---
`Pt_CB_GEN_TREE_INPUT` | This callback is generated from mouse and key events.

## Associated Classes

`PtGenTreeInput`, `PtCallbackInfo`

Prev | Home | Next
`PtGenList` | Up | `PtGraphic`

Copyright 1995-2002 by Cogent Real-Time Systems, Inc.