[Qt-interest] How to get mouse cursor position from QEvent
Ulf-Alexander v. Ceumern-Lindenstjerna
ceumern at vrmagic.com
Mon Feb 22 17:54:50 CET 2010
Hi.
I was just about to suggest casting the event to a QMouseEvent, when I
saw that QWidget::enterEvent ( QEvent * event ) receives a plain
"QEvent". Kind of strange, since this is an event triggered by mouse
interaction. Is there a reason for it that I can't see?
/Ulf
> -----Original Message-----
> From: qt-interest-bounces at trolltech.com [mailto:qt-interest-
> bounces at trolltech.com] On Behalf Of Steven Chang
> Sent: Monday, February 22, 2010 5:23 PM
> To: qt-interest at trolltech.com
> Subject: [Qt-interest] How to get mouse cursor position from QEvent
>
> Dear Sir,
>
>
>
> I re-implement Qt QWidget's protected function "void enterEvent(QEvent
> *event);".
>
> How can I get the enter point or mouse cursor position from the
> parameter(*event) of enterEvent function?
>
> Thanks a lot!
>
>
>
> Best Regards,
>
> Steven
More information about the Qt-interest-old
mailing list