# You can get the coordinates of the upper-left corner of a widget by # using the x and y methods. # The coordinates they return are relative to the parent of the widget: $x = $widget->x; $y = $widget->y; # for a mouse pointer my ($x, $y) = $mw->pointerxy;