Warning: main(/www/www/htdocs/style/globals.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/photon/lib_ref/pt/ptfindsurface.html on line 1

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/globals.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/photon/lib_ref/pt/ptfindsurface.html on line 1

Warning: main(/www/www/htdocs/style/header.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/photon/lib_ref/pt/ptfindsurface.html on line 8

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/header.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/photon/lib_ref/pt/ptfindsurface.html on line 8

PtFindSurface()

Find the control surface with a given ID

Synopsis:

PtSurface_t *PtFindSurface( PtWidget_t *widget,
                            unsigned char surface_id );

Library:

ph

Description:

This function locates a control surface belonging to a given widget, using the surface's numerical ID, surface_id, as a search key.

Returns:

A pointer to the structure representing the control surface, or NULL if the specified surface couldn't be found.


Note: Since control surfaces are maintained internally as an array, it's not uncommon for them to shift around in memory as surfaces are added and removed, thereby possibly invalidating a pointer returned by this function. As such, all surface pointers should be regarded as transient, and you should retrieve an updated copy whenever there's a chance that the widget's surface configuration might have changed.

Classification:

Photon

Safety:
Interrupt handler No
Signal handler No
Thread No

See also:

PtFindSurfaceByAction(), PtWidgetActiveSurface()

Control Surfaces chapter of the Photon Programmer's Guide


Warning: main(/www/www/htdocs/style/footer.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/photon/lib_ref/pt/ptfindsurface.html on line 108

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/footer.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/photon/lib_ref/pt/ptfindsurface.html on line 108