problem finding the position of a button in the gtk dialog



I am trying to find the position of a button in a gtk dialog.
but getting some strange results..

approach i am using is :
i will find the distance of the button from its parent, and then its
parent's distance form its parent .. and so on, till i get toplevel window.
then i am adding the decoration's height, border's width and distance of top
level window from origin of root window(0,0).

i am getting same (x,y) pair for the each level of iteration :(.

sample code i wrote is attached with this mail...

It will be great if someone can point out the mistake or can tell the
correct code for this.




-- 
********************************************************************************
* LiFe iS BeaUTiFuL, LiVE iT To THe FuLLeST ----- CHiRaG JuNeJa *
********************************************************************************


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