Stack Exchange network consists of 183 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
The specific command I'm trying to set is bpy.ops.object.origin_set() which sets the origin of an object which is bound to default to Ctrl +Shift+Alt +C
$\begingroup$What is your actual goal? Creating a shortcut for Origin to 3D cursor without getting the menu? Search for origin and see how that's done. Your test doesn't work because you have use the identifier of the desired operator not the function() call.$\endgroup$
$\begingroup$Yeah duh, in this case. What about Pivot center? Viewport shading? Interaction Mode? I'm coming from here: blender.stackexchange.com/questions/7878/…$\endgroup$
$\begingroup$See my edit here. Also consider that you can always right-click the relevant button within the UI to change the shortcut and notice that all previously registered shortcuts listed in User Preferences > Input as mentioned before...$\endgroup$
origin
and see how that's done. Your test doesn't work because you have use theidentifier of the desired operator
not thefunction()
call. $\endgroup$origin
... $\endgroup$