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/ptwidgetoffset.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/ptwidgetoffset.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/ptwidgetoffset.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/ptwidgetoffset.html on line 8
Find the offset of a widget's origin
PhPoint_t *PtWidgetOffset( PtWidget_t *widget,
PhPoint_t *offset );
ph
This function determines the offset of widget's origin from
its disjoint parent widget and stores it in the
PhPoint_t
structure pointed to by offset.
A pointer to a
PhPoint_t structure that's the offset of the
widget's origin from its parent window (the widget's position
is relative to this point), or NULL if an error occurs.
PtArg_t arg;
PhPoint_t *widget_pos;
PtSetArg( &arg, Pt_ARG_POS, &widget_pos, 0);
PtGetResources( labelwidget, 1, &arg );
if(PtWidgetOffset( labelwidget, &point))
{
widget_position_relative_to_window.x =
point.x + widget_pos->x;
widget_position_relative_to_window.y =
point.y + widget_pos->y;
}
Photon
Safety: | |
Interrupt handler |
No |
Signal handler |
No |
Thread |
No |
PhPoint_t,
PhTranslateRect(),
PtGetAbsPosition()
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/ptwidgetoffset.html on line 112
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/ptwidgetoffset.html on line 112