[Qt-interest] how to get globalPos()

Malyushytsky, Alex alex at wai.com
Thu Mar 26 22:13:12 CET 2009


You are probably looking For the following finctions:

QPoint pos () const
QRect frameGeometry () const

Above functions will give you results in coordinates related to parent.

You might need to map the to what you want, using map functions like:

QPoint QWidget::mapToGlobal ( const QPoint & pos ) const


Check documentation for 'Window Geometry' and search for 'map' in QWidget for more information.

Regards,
    Alex

________________________________________
From: qt-interest-bounces at trolltech.com [mailto:qt-interest-bounces at trolltech.com] On Behalf Of chandrasekar wagmare
Sent: Thursday, March 26, 2009 4:52 AM
To: qt-interest at trolltech.com
Subject: [Qt-interest] how to get globalPos()

how to get globalPos of a widget without using mouseEvent ... because i wan to display a tooltip over a pushbutton and shows it automatically ... without using mouse ....
    how can i get it .... ?

--
CHANDRU


---------------------------------------------------------------------------------------------------
Weidlinger Associates, Inc. made the following annotations.

"This message and any attachments are solely for the intended recipient and may contain confidential or privileged information. If you are not the intended recipient, any disclosure, copying, use, or distribution of the information included in this message and any attachments is prohibited. If you have received this communication in error, please notify us by reply e-mail and immediately and permanently delete this message and any attachments. Thank you."

"Please consider our environment before printing this email."




More information about the Qt-interest-old mailing list