pymel.core.general.toolDropped

static general.toolDropped(*args, **kwargs)

This command builds and executes the commands necessary to recreate the specified tool button. It is invoked when a tool is dropped on the shelf.

Derived from mel command maya.cmds.toolDropped

Example:

import pymel.core as pm

# Create move tool button and scale tool button in a new window
pm.window()
# Result: ui.Window('window1') #
pm.columnLayout()
# Result: ui.ColumnLayout('window1|columnLayout23') #
pm.toolCollection()
# Result: ui.ToolCollection('window1|columnLayout23|toolCollection4') #
pm.toolButton( tool='moveSuperContext', toolImage1=('moveSuperContext', 'move_M.png') )
# Result: ui.ToolButton('window1|columnLayout23|toolButton8') #
pm.toolButton( tool='scaleSuperContext', toolImage1=('scaleSuperContext', 'scale_M.png') )
# Result: ui.ToolButton('window1|columnLayout23|toolButton9') #
pm.showWindow()

# Drop select tool to the created window
pm.toolDropped('selectTool')

Previous topic

pymel.core.general.toggleAxis

Next topic

pymel.core.general.toolHasOptions

Core

Core Modules

Other Modules

This Page