def __init__(self, label=None, name=None, command=None, annotation='', shelfLabel='', shelfIcon='render_useBackground', readUI_toArgs={}, **kwargs):
'''
The fancy part of this object is the readUI_toArgs argument.
'''
self.uiArgDict = readUI_toArgs
self.name = name
self.command = command
self.kwargs = kwargs
self.annotation = annotation
self.shelfLabel = shelfLabel
self.shelfIcon = shelfIcon
if annotation and not annotation.endswith('.'):
annotation+='.'
button = mc.button(label=label, command=self.runCommand, annotation=annotation+' Or right click for more options.')
mc.popupMenu()
mc.menuItem(label='Create Shelf Button', command=self.createShelfButton, image=shelfIcon)
mc.menuItem(label='Create Hotkey',
command=self.createHotkey, image='commandButton')
评论列表
文章目录