--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_m...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/56569e89-0ade-4022-8372-a96e36bbb437%40googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_maya+unsub...@googlegroups.com.
It should never go above 20, maybe 30 items maximum. However, it would be complex widgets, with variation in the content.
So when you used drag/drop widget implementation, you did it like the documentation suggested ? i.e. , assuming you want to move widget A- duplicate A- render A as pixmap (place holder)- put this place holder to replace A- attach A to your mouse cursor, set a reduced opacity- perform the reorder where you drop A- remove place holderDo you have a code example, by any chance?
Le mercredi 8 avril 2020 17:47:41 UTC-4, Justin Israel a écrit :
I've used both a custom drag and drop widget implementation, and the drag and drop teatures within a tree/list widget. However I have never used the tree/list widget as a workaround for something suited to a custom implementation. I've used the tree/list approach when I am actually using the model to supply the data, and the widget as a way to represent the data. So I can't really comment on your "trick" approach. If it works fine and is easy to maintain and control, then I can't say its a wrong approach. It depends on how many items you will have in the tree/list and whether you see performance issues.
On Thu, Apr 9, 2020 at 9:38 AM vince touache <fruit...@gmail.com> wrote:
hi guys,--I'm looking at implementing a drag&drop to reorder a list of widgets in Qt. Turns out it's more complicated than what I expected and involves a lot of low-level work (https://stackoverflow.com/questions/18299077/dragging-a-qwidget-in-qt-5)Nothing crazy, but still a lot of -not obvious- codeInstead, I was wondering if it wouldn't be smarter to use a QTreeWidget, and add my widgets as QTreeWidgetItems, and therefore benefit from the native QTreeWidget drag&drop mechanism.It works fine in a proof of concept, is much shorter and much more readable than implementing the drag&drop myself.. even works better in the behavior! But having it on a complete tool, in production conditions, is something else...Did anyone face this issue before? Which option did you go for, the brute force implementation, or the QTreeWidget/QListWidget trick?Thanks !
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_m...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/56569e89-0ade-4022-8372-a96e36bbb437%40googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_m...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/b687ee38-7a47-4292-9718-890bae6587bc%40googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_maya+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/56569e89-0ade-4022-8372-a96e36bbb437%40googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_maya+unsub...@googlegroups.com.