-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Added QWidget #3
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey, first, let me apologize for taking forever to look at this. I switched jobs in between other things as you made the PR and forgot to look at it for a long while.
@2b-t Thank you very much for doing this work. I would have liked to have it done as a QWidget, but I did not get there!
I have a few comments in this PR which are basically minor in regards of return
s that are either unnecessary (and I had some of them in my code already!) or that I'd prefer to have an explicit return of None
to help other possible contributors understand what is going on by being explicit (this is a personal preference, I'm open to discussion as I may be missing something).
I'm keen to merge this. If you have the time to attend my comments, that would be great.
There's one thing that would worry me a bit, which is that the plugin name has changed from RqtEmbedWindowWidget
to EmbedWindowWidget
(which makes total sense) and that could break people's code that points to the old name. I wonder if we can do a wrapper for the old plugin name that just calls the new one, so when merging this into main we won't be breaking anyone's code?
Maybe it's a lost cause and it would break people's rqt configs anyways.
Again, thanks a lot, and I apologize for not merging straight away.
Hey @awesomebytes |
…s was created and widget is closed
@awesomebytes I just removed all unnecessary returns and made the others explicitly
in case no process was added to the widget and the widget was closed. I also checked back on the naming of the widget and the file that I changed from camel case to underscores removing the leading The changes are only relevant in case somebody would refer to
In case you are worried that somebody might have done latter we could add a file called Taking these things into consideration I think this is a very unlikely scenario and I would still keep the changes in naming in order to be consistent with the other rqt packages. |
Hey @awesomebytes |
Hi @awesomebytes |
The disadvantage of the current code is that the widget itself is directly implemented in the plugin. This way somebody can't embed the GUI into his/her own GUI easily (like in this tutorial here). Therefore I have
Plugin
and theQWidget
(just like most of the otherrqt
packages do)I made a simple example of how this can be useful here (also see image below). Furthermore this somehow seems to solves the issue pointed out in #2.