PhabNameWidgets

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

# `PhabNameWidgets`

`PhabNameWidgets` -- assigns global variables to widget names.

## Syntax

    PhabNameWidgets(hierarchy)

## Arguments

`hierarchy`

  The widget hierarchy to which global variables will be assigned.

## Returns

Doesn't return any useful value.

## Description

This function walks a widget hierarchy and creates global variables of the same name as, and referring to, each of the widgets in the hierarchy that has a name.

To use this function, you must load the PhabTemplate.lsp library with a call to `require_lisp("PhabTemplate.lsp")`.

## Example

This example, `ex_PhabNameWidgets.g`, is included in the `gamma_ph_`#`_examples_1_QNX4.tgz` file available on the Cogent Web Site.

    #!/usr/cogent/bin/phgamma

    /*
    This example loads and displays a window, as in the example for
    PhabLoad().  But here we use each function separately, including
    PhabNameWidgets().
    */

    PtInit(nil);
    require_lisp("PhabTemplate.lsp");

    file = PhabReadWidgetFile("WidgetFiles/wgt/loadwindow.wgtw");
    win = PhabCreateWidgets(file,nil,nil);
    PhabNameWidgets(win);
    PtRealizeWidget(MainWindow);

    PtMainLoop();

## See Also

PhabLoad

Prev | Home | Next
`PhabLookupWidget` | Up | `PhabReadWidget`

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