Hey Justin, that's exactly what I was looking for. Thanks you very much. I tried other widgets too and it works, great!
*Carlos Rico Adega *Maya Generalist* *------------------------------------- <http://www.vimeo.com/16765581> LinkedIn<http://www.linkedin.com/pub/carlos-rico/6/58/325> [email protected] 2013/6/14 Justin Israel <[email protected]> > I threw together a quick example that seems to work fine: > https://gist.github.com/justinfx/5778557 > > You just need to translate your qt button into the maya path, so you can > give it to the marking menu as the parent. > > Is that what you are after? > > > > On Fri, Jun 14, 2013 at 11:21 AM, CharlieWales <[email protected]>wrote: > >> Thanks for the responses. I will assume that, one, I cannot attach a Maya >> marking menu to a PyQt widget and two, I cannot recreate a marking menu >> with PyQt, meaning having items in north, south, east, west, etc. >> positions. I guess I have to stick to regular Qt context menus or use Maya >> buttons instead of QPushButton when I want to make use of Maya marking >> menus. Correct me if I am wrong. Thanks. >> >> El 14/06/2013 00:26, "Christian Akesson" <[email protected]> >> escribió: >> >> On Thursday, June 13, 2013 12:53:06 PM UTC-7, Justin Israel wrote: >>> > Is that a marking menu or just a normal menu? He was asking about >>> marking menus. >>> > >>> > On Jun 14, 2013 7:03 AM, "Christian Akesson" <[email protected]> >>> wrote: >>> > >>> > To populate context menu >>> > >>> > # Clear the list >>> > >>> > for e in myContextMenu .actions(): >>> > >>> > myContextMenu.removeAction(e) >>> > >>> > # Populate the list >>> > >>> > if dataItems: >>> > >>> > myContextMenu.addAction(PyQt4.QtGui.QAction('Reset', self)) >>> > >>> > myContextMenu.addSeparator() >>> > >>> > for e in dataItems: >>> > >>> > myContextMenu.addAction(PyQt4.QtGui.QAction('%s' % e, self)) >>> > >>> > >>> > >>> > -- >>> > >>> > 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 [email protected]. >>> > >>> > To post to this group, send email to [email protected]. >>> > >>> > For more options, visit https://groups.google.com/groups/opt_out. >>> >>> Sorry misunderstood, I thought he was asking for popUp as an >>> alternative. Disregard the info :-) >>> >>> -- >>> 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 [email protected]. >>> To post to this group, send email to [email protected] >>> . >>> For more options, visit https://groups.google.com/groups/opt_out. >>> >>> >>> -- >> 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 [email protected]. >> To post to this group, send email to [email protected]. >> For more options, visit https://groups.google.com/groups/opt_out. >> >> >> > > -- > 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 [email protected]. > To post to this group, send email to [email protected]. > For more options, visit https://groups.google.com/groups/opt_out. > > > -- 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 [email protected]. To post to this group, send email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
