Title: `QwtPlot.setMouseTracking` is ignored · Issue #88 · PlotPyStack/PythonQwt · GitHub
Open Graph Title: `QwtPlot.setMouseTracking` is ignored · Issue #88 · PlotPyStack/PythonQwt
X Title: `QwtPlot.setMouseTracking` is ignored · Issue #88 · PlotPyStack/PythonQwt
Description: I want to detect the mouse move events over my qwt plot. According to mouseMoveEvent docs: If mouse tracking is switched off, mouse move events only occur if a mouse button is pressed while the mouse is being moved. If mouse tracking is ...
Open Graph Description: I want to detect the mouse move events over my qwt plot. According to mouseMoveEvent docs: If mouse tracking is switched off, mouse move events only occur if a mouse button is pressed while the mou...
X Description: I want to detect the mouse move events over my qwt plot. According to mouseMoveEvent docs: If mouse tracking is switched off, mouse move events only occur if a mouse button is pressed while the mou...
Opengraph URL: https://github.com/PlotPyStack/PythonQwt/issues/88
X: @github
Domain: patch-diff.githubusercontent.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"`QwtPlot.setMouseTracking` is ignored","articleBody":"I want to detect the mouse move events over my qwt plot.\r\n\r\nAccording to [`mouseMoveEvent` docs](https://doc.qt.io/qtforpython-6/PySide6/QtWidgets/QWidget.html#PySide6.QtWidgets.QWidget.mouseMoveEvent):\r\n\r\n\u003e If mouse tracking is switched off, mouse move events only occur if a mouse button is pressed while the mouse is being moved. If mouse tracking is switched on, mouse move events occur even if no mouse button is pressed.\r\n\r\nTo enable the mouse tracking it should be enough to invoke [`setMouseTracking(True)`](https://doc.qt.io/qtforpython-6/PySide6/QtWidgets/QWidget.html#PySide6.QtWidgets.QWidget.setMouseTracking) but it seems to me that it is ignored.\r\n\r\n```python\r\nfrom qwt.plot import QwtPlot\r\nfrom PySide6.QtGui import QMouseEvent\r\n\r\nclass MyPlot(QwtPlot):\r\n def __init__(self) -\u003e None:\r\n super().__init__()\r\n self.setMouseTracking(True)\r\n def mouseMoveEvent(self, event: QMouseEvent) -\u003e None:\r\n print(event) # dummy implementation\r\n```\r\n\r\nI see the events in the stdout only if I keep the mouse button pressed, not just on \"hovering\" over the plot","author":{"url":"https://github.com/ZeeD","@type":"Person","name":"ZeeD"},"datePublished":"2024-08-15T10:24:52.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":1},"url":"https://github.com/88/PythonQwt/issues/88"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:b3226d78-b157-8507-54c8-48ca5dca4393 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | B700:19F72D:1CD9432:27B4662:69739264 |
| html-safe-nonce | a70e52637404b34fd79fc3bf671b659ed725545c8ba09e4e7560a5876afd7a19 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCNzAwOjE5RjcyRDoxQ0Q5NDMyOjI3QjQ2NjI6Njk3MzkyNjQiLCJ2aXNpdG9yX2lkIjoiNDg5OTcyODg4MjM3MTEwNTM4MCIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 85d4dca8fbc9bf7e935966e2d7bfc418737a6a0cebd35ee8b69bac0cdddcefea |
| hovercard-subject-tag | issue:2467802307 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/PlotPyStack/PythonQwt/88/issue_layout |
| twitter:image | https://opengraph.githubassets.com/c47cb87a0d0937b5d962730dd728342971ea7eeb1c6f3ba9e4a28c1480bb9221/PlotPyStack/PythonQwt/issues/88 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/c47cb87a0d0937b5d962730dd728342971ea7eeb1c6f3ba9e4a28c1480bb9221/PlotPyStack/PythonQwt/issues/88 |
| og:image:alt | I want to detect the mouse move events over my qwt plot. According to mouseMoveEvent docs: If mouse tracking is switched off, mouse move events only occur if a mouse button is pressed while the mou... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | ZeeD |
| hostname | github.com |
| expected-hostname | github.com |
| None | f0b5e2d1da32de5a0b7bcfbc5ba007c93e8e63098fba29e1200efb674aa72e66 |
| turbo-cache-control | no-preview |
| go-import | github.com/PlotPyStack/PythonQwt git https://github.com/PlotPyStack/PythonQwt.git |
| octolytics-dimension-user_id | 145201262 |
| octolytics-dimension-user_login | PlotPyStack |
| octolytics-dimension-repository_id | 41204495 |
| octolytics-dimension-repository_nwo | PlotPyStack/PythonQwt |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 41204495 |
| octolytics-dimension-repository_network_root_nwo | PlotPyStack/PythonQwt |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 6fc3acd8abe8a5ec0c4bf4d09d9e27d14301112d |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width