1. QPoint QMouseEvent::pos()
这个只是返回相对这个widget(重载了QMouseEvent的widget)的位置。
const Returns the position of the mouse cursor, relative to the widgetthat received the event. If you move the widget as a result of the mouse event,use the global position returned by globalPos() to avoid a shaking motion.
2. QPoint QMouseEvent::globalPos()
窗口坐标,这个是返回鼠标的全局坐标
const Returns the global position of the mouse cursor at the time of theevent. This is important on asynchronous window systems like X11. Whenever youmove your widgets around in response to mouse events, globalPos() may differ alot from the current pointer position QCursor::pos(), and fromQWidget::mapToGlobal(pos()).
3. QPoint QCursor::pos() [static]