Shortcuts are cool but I believe it'd be cooler to assign multiple actions on them. Perhaps I entered the scripting area since I've seen addons that implement things I describing right now like "apply rot and scale, set origin to center of mass, selection to world origin". People are creating their own menus for that but I can clearly see how modular and customizable Blender is, so I can't say where the basic functionality ends and scripting starts.

  • $\begingroup$ In general it's not possible to assign a shortcut to a chain of actions, except, as you mention, by writing a python script to perform the chain and assigning the shortcut to it. $\endgroup$ Mar 22, 2022 at 20:01
  • $\begingroup$ I think bpy.types.Macro is the thing you're looking for. I have never used it but I think you'll catch a few interesting links using the keyword $\endgroup$
    – Gorgious
    Mar 22, 2022 at 20:15
  • $\begingroup$ You may consider create a operator that to execute many of operator. $\endgroup$
    – X Y
    Mar 22, 2022 at 22:33

1 Answer 1


This is a operator example with short cut Ctrl F9 to do Snap Cursor to Selected and Center View to Cursor

import bpy

# Snap Cursor to Selected and Center View to Cursor
class MY_OP(bpy.types.Operator):
    bl_idname = "view3d.my_operator"
    bl_label = "Operator"

    def invoke(self, context, event):
        return {'FINISHED'}

addon_keymaps = []
def register():

    # Add the hotkey
    wm = bpy.context.window_manager
    kc = wm.keyconfigs.addon
    if kc:
        km = wm.keyconfigs.addon.keymaps.new(name='3D View', space_type='VIEW_3D')
        kmi = km.keymap_items.new("view3d.my_operator", type='F9', value='PRESS', ctrl=True)
        addon_keymaps.append((km, kmi))

def unregister():

    # Remove the hotkey
    for km, kmi in addon_keymaps:

if __name__ == "__main__":

On the other hand, You can install this to addon then you not need run this script every time when blender startup.


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .