View Full Version : [SOLVED] Get the position of a QT widget?

February 2nd, 2010, 04:07 PM
How can I get the position of a QT widget? This may not be the right way of going about this, but I want to draw a pixmap on top of a button to label it. In any case, being able to determine the position of a widget in a window probably has other applications. I am very new to QT so I don't really know what I'm doing.

February 2nd, 2010, 04:20 PM

Basically returns a QPoint that contains the widget's position.

If I understand, you want an image on the button? I believe the button widget already has a function to do that, I just can't remember it at this moment. Might want to check out this (http://doc.trolltech.com/4.6/qpushbutton.html) page

February 2nd, 2010, 05:07 PM
Thank you!