Title: Implementing signals and slots · Issue #44 · MeVisLab/pythonqt · GitHub
Open Graph Title: Implementing signals and slots · Issue #44 · MeVisLab/pythonqt
X Title: Implementing signals and slots · Issue #44 · MeVisLab/pythonqt
Description: I'm trying to implement a custom signal and slot but there seem to be a few errors. I can't inherit from QObject(which seems to be the recommended way) as it doesn't exist. This example throws: AttributeError: module 'PythonQt.QtCore' ha...
Open Graph Description: I'm trying to implement a custom signal and slot but there seem to be a few errors. I can't inherit from QObject(which seems to be the recommended way) as it doesn't exist. This example throws: Att...
X Description: I'm trying to implement a custom signal and slot but there seem to be a few errors. I can't inherit from QObject(which seems to be the recommended way) as it doesn't exist. This example...
Opengraph URL: https://github.com/MeVisLab/pythonqt/issues/44
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Implementing signals and slots","articleBody":"I'm trying to implement a custom signal and slot but there seem to be a few errors.\r\nI can't inherit from QObject(which seems to be the recommended way) as it doesn't exist. [This](https://sourceforge.net/p/pythonqt/discussion/631393/thread/bbc98b8f/https://sourceforge.net/p/pythonqt/discussion/631393/thread/bbc98b8f/) example throws:\r\n`AttributeError: module 'PythonQt.QtCore' has no attribute 'QObject' `\r\nThe discussion [here](https://sourceforge.net/p/pythonqt/discussion/631393/thread/bbc98b8f/) doesn't seem to be resolved either.\r\n\r\n If I do it without classes like so:\r\n```\r\nfrom PythonQt.QtCore import Signal\r\ndef slot():\r\n print(\"something\")\r\nsig = Signal(\"QVariant\") # also tried without QVariant\r\nsig.connect(slot)\r\nsig.emit()\r\n```\r\nIt results in a crash due to segmentation fault.\r\nI'm new to Qt itself so would love any suggestions/right way of doing things. Thank You.","author":{"url":"https://github.com/nikhil-sethi","@type":"Person","name":"nikhil-sethi"},"datePublished":"2021-04-13T11:54:46Z","url":"https://github.com/MeVisLab/pythonqt/issues/44"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| 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:317b6d66-4850-77d5-cb70-38708179c1db |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | BA8C:11F3D7:1764:1E46:6AFF6C84 |
| html-safe-nonce | aa37f7c654794b4c40fbbc8def583e39bf883e5848bb2a515896a5ce459ffa61 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCQThDOjExRjNENzoxNzY0OjFFNDY6NkFGRjZDODQiLCJ2aXNpdG9yX2lkIjoiNjA1NTQ5MDEzMzQ4MDY2NDE5NyIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 8a2f081148b3a37824ce13e78511e455ff844c7f63e498af455808df90a1c3c9 |
| hovercard-subject-tag | issue:856886783 |
| 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/MeVisLab/pythonqt/44/issue_layout |
| twitter:image | https://opengraph.githubassets.com/b18580afd696214f0231acd98f380d5c1530d1d2537fe8fbe17b93d445162dec/MeVisLab/pythonqt/issues/44 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/b18580afd696214f0231acd98f380d5c1530d1d2537fe8fbe17b93d445162dec/MeVisLab/pythonqt/issues/44 |
| og:image:alt | I'm trying to implement a custom signal and slot but there seem to be a few errors. I can't inherit from QObject(which seems to be the recommended way) as it doesn't exist. This example throws: Att... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | nikhil-sethi |
| hostname | github.com |
| expected-hostname | github.com |
| None | 6d580fc7098c193d7866bf290c4c2b4859a153e87379f44161f35a4495e6b730 |
| turbo-cache-control | no-preview |
| go-import | github.com/MeVisLab/pythonqt git https://github.com/MeVisLab/pythonqt.git |
| octolytics-dimension-user_id | 15028021 |
| octolytics-dimension-user_login | MeVisLab |
| octolytics-dimension-repository_id | 193056137 |
| octolytics-dimension-repository_nwo | MeVisLab/pythonqt |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 193056137 |
| octolytics-dimension-repository_network_root_nwo | MeVisLab/pythonqt |
| 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 | ec5dd94a369dad6e9ce618a1705cbe3b618a2863 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width