Re: Finding absolute position of widget on the screen



"Padraig O'Briain" <Padraig Obriain Sun COM> writes:
I am trying to figure out what functions I should be using to find
the absolute position of a widget.


You may want to read recent gtk-devel-list posts/patches about window
positions. In particular in my recent patch I also add API docs to the
GDK functions.

gdk_window_get_origin() will get the position of a window in root
window coordinates. So call that on widget->window for the toplevel
window.

gdk_window_get_root_origin() gets the position of the top-left corner
of the titlebar.

Havoc




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]