How to set up keyboard shortcut for bounding box viewport shading? I want to set up key shortcuts for viewport shading modes. Problem is, I can’t figure out which keyword is the mode for Bounding Box.

I’ve got the other ones working, Rendered, Material, Textured, Solid, Wireframe all work.

I’ve tried the following: BOUNDINGBOX, BOUNDING_BOX, BOUNDING, BOX, BOUNDS, and several variations, none work.

Here are the user input values:


Might you know which keyword works for “Bounding Box”?

Thanks.

Edit: In case it helps, the Context value is: space_data.viewport_shade
Go over to the 3D View Header, right click over the Viewport Shading Mode menu and choose the option Online Python reference.

That should take you to the Blender's Official Python API Documentation where you can learn all about it.

There you will learn that the the viewport_shadeproperty is an enum that accepts [‘BOUNDBOX’, ‘WIREFRAME’, ‘SOLID’, ‘TEXTURED’, ‘MATERIAL’, ‘RENDERED’]string values.

The one you are looking for would hence be BOUNDBOX.