Practical Maya Programming with Python by Robert Galanakis
Author:Robert Galanakis [Galanakis, Robert]
Language: eng
Format: epub, pdf
Publisher: Packt Publishing
Published: 2014-07-25T07:00:00+00:00
We create a setdefault callback function, and connect it to the action's triggered signal. The triggered signal is emitted when the menu item is clicked.
Let's see this in action. We'll need to reset our font and then re-register the item. Run this from the Script Editor.
action.setFont(QtGui.QFont()) reload(newmenumarker) newmenumarker.register_menuitem(menuitem)
Our menu item should now have a bold font. After we click it, the font should return to normal.
While the current code serves as a demonstration for customizing menus, it still needs some work to be functional enough for non-demonstration use. Let's go ahead and set up a more complex use case, and add a persistence layer so that the menu items remember whether they are marked or not between Maya sessions.
Download
Practical Maya Programming with Python by Robert Galanakis.pdf
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.
Implementing Enterprise Observability for Success by Manisha Agrawal and Karun Krishnannair(7257)
Supercharging Productivity with Trello by Brittany Joiner(6522)
Secrets of the JavaScript Ninja by John Resig Bear Bibeault(6409)
Mastering Tableau 2023 - Fourth Edition by Marleen Meier(6286)
Inkscape by Example by István Szép(6137)
Visualize Complex Processes with Microsoft Visio by David J Parker & Šenaj Lelić(5837)
Build Stunning Real-time VFX with Unreal Engine 5 by Hrishikesh Andurlekar(4821)
Design Made Easy with Inkscape by Christopher Rogers(4552)
Customizing Microsoft Teams by Gopi Kondameda(4097)
Linux Device Driver Development Cookbook by Rodolfo Giometti(3932)
Extending Microsoft Power Apps with Power Apps Component Framework by Danish Naglekar(3684)
Business Intelligence Career Master Plan by Eduardo Chavez & Danny Moncada(3615)
Salesforce Platform Enterprise Architecture - Fourth Edition by Andrew Fawcett(3558)
Pandas Cookbook by Theodore Petrou(3540)
The Tableau Workshop by Sumit Gupta Sylvester Pinto Shweta Sankhe-Savale JC Gillet and Kenneth Michael Cherven(3341)
TCP IP by Todd Lammle(2981)
Drawing Shortcuts: Developing Quick Drawing Skills Using Today's Technology by Leggitt Jim(2909)
Applied Predictive Modeling by Max Kuhn & Kjell Johnson(2857)
Work Smarter with Microsoft OneNote by Connie Clark(2840)
