Blender 3D: Noob to Pro/Advanced Tutorials/Blender Scripting/Object, Action, Settings

From Wikibooks, open books for an open world
Jump to: navigation, search

Now that we’ve covered the basics of writing a working addon and making it installable, let’s add some refinements to its functionality.

To start with, users normally add new objects via the Add menu which pops up when pressing  SHIFT + A , rather than via a custom panel. Can our script add a new “Tetrahedron” item to that menu? Yes it can.

Also, our script currently requires us to adjust its setting (the “Upside-Down” checkbox) before it performs its action. In user-interface parlance, this is the ordering “Object→Setting→Action”: select an object, specify the settings for the action, then perform the action. Whereas the preferred order in Blender 2.5x is “Object→Action→Setting”: which means the action is performed with some initial settings, which the user is then free to modify while observing their effect. This gives a much smoother workflow, rather than the user having to guess what the effects will be before applying them, and then undoing and trying again if they guessed wrong.

(Of course, since our example script creates a new object rather than modifying an existing one, the initial “Object” step is not relevant here. But it is to other operators.)

So the modifications we need to make to our script are:

  • Get rid of the existing Panel subclass.
  • Our register function will add a new entry to the Add menu (specifically, the mesh-add submenu) to invoke our Operator subclass.
  • When our operator is invoked, a panel will appear, with all the settings controls we previously had, except for the “Add” button. The user can play with these settings, and observe the effect on the newly-created object immediately.

The nice thing is, Blender does most of the hard work for us, so we only need to edit a few lines of code to achieve all the above!

Adding To The Add Menu[edit]

This needs to be done in two steps. First we need a function which will be invoked when Blender creates its Add menu: this will add an entry that invokes our custom operator by its name. Specifically, we will add our custom item to the “Mesh” submenu of the “Add” menu. We can also assign an icon to the menu item; here I’m using the generic plugin icon:

def add_to_menu(self, context) :
    self.layout.operator("mesh.make_tetrahedron", icon = "PLUGIN")
#end add_to_menu

Having done that, we change our register function to add our add_to_menu item to a list that Blender uses to create its Add→Mesh menu:

def register() :
    bpy.utils.register_class(MakeTetrahedron)
    bpy.types.INFO_MT_mesh_add.append(add_to_menu)
#end register

Note this bpy.types.INFO_MT_mesh_add object is not currently mentioned in the API documentation; I found it by examining the scripts that come bundled with Blender.

And of course we should clean up ourselves, so the unregister function needs to remove the item we added:

def unregister() :
    bpy.utils.unregister_class(MakeTetrahedron)
    bpy.types.INFO_MT_mesh_add.remove(add_to_menu)
#end unregister

Fixing Up The UI[edit]

Note that previously, our register and unregister functions were attaching a custom property to Blender’s Scene class to hold our setting value. That code is now gone, but we still need the property. Instead, it will now be attached directly to our MakeTetrahedron class.

Also, remember we said we were getting rid of the TetrahedronMakerPanel class? In fact we keep the draw method from that, and move it to our MakeTetrahedron operator, only getting rid of the last button in the panel for invoking the operator. This is because by the time the panel is being drawn, the operator has already been invoked.

We also need to tell Blender that we are conforming to the Object→Action→Settings convention, by adding the "REGISTER" item to our bl_options.

So the header of our operator class now looks like this:

class MakeTetrahedron(bpy.types.Operator) :
    bl_idname = "mesh.make_tetrahedron"
    bl_label = "Tetrahedron"
    bl_options = {"REGISTER", "UNDO"}
 
    inverted = bpy.props.BoolProperty \
      (
        name = "Upside Down",
        description = "Generate the tetrahedron upside down",
        default = False
      )
 
    def draw(self, context) :
        TheCol = self.layout.column(align = True)
        TheCol.prop(self, "inverted")
    #end draw

Previously our custom property was called make_tetrahedron_inverted, but here I just call it inverted, because after all it is being attached to our own class, so there should be no worry about name clashes.

Note that I also changed the bl_label text, taking out the word “Add”. This is redundant, because our label will be appearing in a menu that is already titled “Add”.

invoke Versus execute[edit]

The last thing to do is rearrange the code for actually creating the tetrahedron object. Previously we had it in a method called invoke, and that method will still be called when our operator is selected from the Add→Mesh menu. Then our draw method will be called, so our panel will also appear. But then, if the user makes adjustments to the controls in our panel, Blender will invoke a different operator method, called execute.

To the user, it looks like they are making adjustments to an already-created object. But in fact our execute method can do exactly the same thing as invoke, namely create a new object every time it’s called! Blender will take care of getting rid of previously-created objects, so the user won’t know the difference.

Nice, isn’t it? But in order for this to work, our code needs to do one thing more: ensure that our newly-created object is the only selected, active object. So the following is added after NewObj has been created and linked into the scene:

        bpy.ops.object.select_all(action = "DESELECT")
        NewObj.select = True
        context.scene.objects.active = NewObj

Put It All Together[edit]

Note that the object-creation code has been moved into a common routine that I have called action_common. This can then be called from both the invoke and execute methods.

import math
import bpy
import mathutils
 
class MakeTetrahedron(bpy.types.Operator) :
    bl_idname = "mesh.make_tetrahedron"
    bl_label = "Tetrahedron"
    bl_options = {"REGISTER", "UNDO"}
 
    inverted = bpy.props.BoolProperty \
      (
        name = "Upside Down",
        description = "Generate the tetrahedron upside down",
        default = False
      )
 
    def draw(self, context) :
        TheCol = self.layout.column(align = True)
        TheCol.prop(self, "inverted")
    #end draw
 
    def action_common(self, context) :
        Scale = -1 if self.inverted else 1
        Vertices = \
          [
            mathutils.Vector((0, -1 / math.sqrt(3),0)),
            mathutils.Vector((0.5, 1 / (2 * math.sqrt(3)), 0)),
            mathutils.Vector((-0.5, 1 / (2 * math.sqrt(3)), 0)),
            mathutils.Vector((0, 0, Scale * math.sqrt(2 / 3))),
          ]
        NewMesh = bpy.data.meshes.new("Tetrahedron")
        NewMesh.from_pydata \
          (
            Vertices,
            [],
            [[0, 1, 2], [0, 1, 3], [1, 2, 3], [2, 0, 3]]
          )
        NewMesh.update()
        NewObj = bpy.data.objects.new("Tetrahedron", NewMesh)
        context.scene.objects.link(NewObj)
        bpy.ops.object.select_all(action = "DESELECT")
        NewObj.select = True
        context.scene.objects.active = NewObj
    #end action_common
 
    def execute(self, context) :
        self.action_common(context)
        return {"FINISHED"}
    #end execute
 
    def invoke(self, context, event) :
        self.action_common(context)
        return {"FINISHED"}
    #end invoke
 
#end MakeTetrahedron
 
def add_to_menu(self, context) :
    self.layout.operator("mesh.make_tetrahedron", icon = "PLUGIN")
#end add_to_menu
 
def register() :
    bpy.utils.register_class(MakeTetrahedron)
    bpy.types.INFO_MT_mesh_add.append(add_to_menu)
#end register
 
def unregister() :
    bpy.utils.unregister_class(MakeTetrahedron)
    bpy.types.INFO_MT_mesh_add.remove(add_to_menu)
#end unregister
 
if __name__ == "__main__" :
    register()
#end if

Undocumented Blender[edit]

That INFO_MT_mesh_add object is one of a bunch of undocumented things lurking in the bpy.types module. They all have names of the form prefix_type_restofname, where prefix is an all-uppercase mnemonic for the category of object (mostly a window type, e.g. INFO for the Info window, which is where the main menu bar appears, though there are also names for major object categories like MESH and LAMP), and type indicates the class of object: HT for a window header UI object (bpy.types.Header), MT for a menu (bpy.types.Menu), OT for an operator, and PT for a panel (bpy.types.Panel). The OT ones seem to correspond directly to objects in bpy.ops, but at a lower level; it’s probably easier just to use the official bpy.ops objects. As for the HT, MT and PT objects, these all have append, prepend and remove methods that you can use to customize them: append adds a widget at the end (right or bottom), while prepend puts it at the front (left or top).

Since they aren’t (yet) mentioned in the official Blender documentation, here is a list of all the ones I’ve been able to find:

Operator Category Header Menu Panel
Bone Properties BONE_PT_constraints, BONE_PT_context_bone, BONE_PT_custom_props, BONE_PT_deform, BONE_PT_display, BONE_PT_inverse_kinematics, BONE_PT_relations, BONE_PT_transform, BONE_PT_transform_locks
Movie Clip Editor CLIP_HT_header CLIP_MT_camera_presets, CLIP_MT_clip, CLIP_MT_proxy, CLIP_MT_reconstruction, CLIP_MT_select, CLIP_MT_select_grouped, CLIP_MT_select_mode, CLIP_MT_stabilize_2d_specials, CLIP_MT_track, CLIP_MT_track_color_presets, CLIP_MT_track_color_specials, CLIP_MT_track_transform, CLIP_MT_track_visibility, CLIP_MT_tracking_settings_presets, CLIP_MT_tracking_specials, CLIP_MT_view CLIP_PT_active_mask_point, CLIP_PT_active_mask_spline, CLIP_PT_display, CLIP_PT_footage, CLIP_PT_footage_info, CLIP_PT_marker, CLIP_PT_marker_display, CLIP_PT_mask, CLIP_PT_mask_display, CLIP_PT_mask_layers, CLIP_PT_objects, CLIP_PT_plane_track, CLIP_PT_proxy, CLIP_PT_stabilization, CLIP_PT_tools_cleanup, CLIP_PT_tools_clip, CLIP_PT_tools_geometry, CLIP_PT_tools_grease_pencil, CLIP_PT_tools_marker, CLIP_PT_tools_mask, CLIP_PT_tools_object, CLIP_PT_tools_orientation, CLIP_PT_tools_plane_tracking, CLIP_PT_tools_solve, CLIP_PT_tools_tracking, CLIP_PT_track, CLIP_PT_track_settings, CLIP_PT_tracking_camera
Cloth Properties CLOTH_MT_presets
Console CONSOLE_HT_header CONSOLE_MT_console, CONSOLE_MT_language
Cycles Renderer CYCLES_MT_integrator_presets, CYCLES_MT_sampling_presets
Object Data Context DATA_PT_active_spline, DATA_PT_area, DATA_PT_bone_group_specials, DATA_PT_bone_groups, DATA_PT_camera, DATA_PT_camera_display, DATA_PT_camera_dof, DATA_PT_cone, DATA_PT_context_arm, DATA_PT_context_camera, DATA_PT_context_curve, DATA_PT_context_lamp, DATA_PT_context_lattice, DATA_PT_context_mesh, DATA_PT_context_metaball, DATA_PT_context_speaker, DATA_PT_curve_texture_space, DATA_PT_custom_props_arm, DATA_PT_custom_props_camera, DATA_PT_custom_props_curve, DATA_PT_custom_props_lamp, DATA_PT_custom_props_lattice, DATA_PT_custom_props_mesh, DATA_PT_custom_props_metaball, DATA_PT_custom_props_speaker, DATA_PT_customdata, DATA_PT_display, DATA_PT_distance, DATA_PT_empty, DATA_PT_falloff_curve, DATA_PT_font, DATA_PT_geometry_curve, DATA_PT_ghost, DATA_PT_iksolver_itasc, DATA_PT_lamp, DATA_PT_lattice, DATA_PT_lens, DATA_PT_mball_texture_space, DATA_PT_metaball, DATA_PT_metaball_element, DATA_PT_modifiers, DATA_PT_motion_paths, DATA_PT_normals, DATA_PT_paragraph, DATA_PT_pathanim, DATA_PT_pose_library, DATA_PT_preview, DATA_PT_shadow, DATA_PT_shadow_game, DATA_PT_shape_curve, DATA_PT_shape_keys, DATA_PT_skeleton, DATA_PT_speaker, DATA_PT_spot, DATA_PT_sunsky, DATA_PT_text_boxes, DATA_PT_texture_space, DATA_PT_uv_texture, DATA_PT_vertex_colors, DATA_PT_vertex_groups
Dopesheet DOPESHEET_HT_header DOPESHEET_MT_channel, DOPESHEET_MT_gpencil_channel, DOPESHEET_MT_gpencil_frame, DOPESHEET_MT_key, DOPESHEET_MT_key_transform, DOPESHEET_MT_marker, DOPESHEET_MT_select, DOPESHEET_MT_view
Filebrowser FILEBROWSER_HT_header
Fluid Simulation FLUID_MT_presets
Graph Editor GRAPH_HT_header GRAPH_MT_channel, GRAPH_MT_key, GRAPH_MT_key_transform, GRAPH_MT_marker, GRAPH_MT_select, GRAPH_MT_view
UV/Image Editor IMAGE_HT_header IMAGE_MT_image, IMAGE_MT_image_invert, IMAGE_MT_select, IMAGE_MT_uvs, IMAGE_MT_uvs_mirror, IMAGE_MT_uvs_select_mode, IMAGE_MT_uvs_showhide, IMAGE_MT_uvs_snap, IMAGE_MT_uvs_transform, IMAGE_MT_uvs_weldalign, IMAGE_MT_view IMAGE_PT_active_mask_point, IMAGE_PT_active_mask_spline, IMAGE_PT_game_properties, IMAGE_PT_image_properties, IMAGE_PT_mask, IMAGE_PT_mask_display, IMAGE_PT_mask_layers, IMAGE_PT_paint, IMAGE_PT_paint_curve, IMAGE_PT_paint_stroke, IMAGE_PT_sample_line, IMAGE_PT_scope_sample, IMAGE_PT_tools_brush_appearance, IMAGE_PT_tools_brush_texture, IMAGE_PT_tools_brush_tool, IMAGE_PT_tools_mask, IMAGE_PT_tools_mask_texture, IMAGE_PT_view_histogram, IMAGE_PT_view_properties, IMAGE_PT_view_vectorscope, IMAGE_PT_view_waveform
Info Window INFO_HT_header INFO_MT_add, INFO_MT_armature_add, INFO_MT_curve_add, INFO_MT_edit_curve_add, INFO_MT_file, INFO_MT_file_export, INFO_MT_file_external_data, INFO_MT_file_import, INFO_MT_game, INFO_MT_help, INFO_MT_mesh_add, INFO_MT_render, INFO_MT_report, INFO_MT_surface_add, INFO_MT_window
Lamp Properties LAMP_MT_sunsky_presets
Logic Editor LOGIC_HT_header LOGIC_MT_logicbricks_add, LOGIC_MT_view LOGIC_PT_properties
Mask Properties MASK_MT_animation, MASK_MT_mask, MASK_MT_select, MASK_MT_transform, MASK_MT_visibility
Material Properties MATERIAL_MT_specials, MATERIAL_MT_sss_presets MATERIAL_PT_context_material, MATERIAL_PT_custom_props, MATERIAL_PT_diffuse, MATERIAL_PT_flare, MATERIAL_PT_halo, MATERIAL_PT_mirror, MATERIAL_PT_options, MATERIAL_PT_physics, MATERIAL_PT_preview, MATERIAL_PT_shading, MATERIAL_PT_shadow, MATERIAL_PT_specular, MATERIAL_PT_sss, MATERIAL_PT_strand, MATERIAL_PT_transp, MATERIAL_PT_transp_game, MATERIAL_PT_volume_density, MATERIAL_PT_volume_integration, MATERIAL_PT_volume_lighting, MATERIAL_PT_volume_options, MATERIAL_PT_volume_shading, MATERIAL_PT_volume_transp
Mesh Properties MESH_MT_shape_key_specials, MESH_MT_vertex_group_specials
NLA Editor NLA_HT_header NLA_MT_add, NLA_MT_edit, NLA_MT_edit_transform, NLA_MT_marker, NLA_MT_select, NLA_MT_view
Node Editor NODE_HT_header NODE_MT_add, NODE_MT_category_CMP_CONVERTOR, NODE_MT_category_CMP_DISTORT, NODE_MT_category_CMP_GROUP, NODE_MT_category_CMP_INPUT, NODE_MT_category_CMP_LAYOUT, NODE_MT_category_CMP_MATTE, NODE_MT_category_CMP_OP_COLOR, NODE_MT_category_CMP_OP_FILTER, NODE_MT_category_CMP_OP_VECTOR, NODE_MT_category_CMP_OUTPUT, NODE_MT_category_SH_CONVERTOR, NODE_MT_category_SH_GROUP, NODE_MT_category_SH_INPUT, NODE_MT_category_SH_LAYOUT, NODE_MT_category_SH_NEW_CONVERTOR, NODE_MT_category_SH_NEW_GROUP, NODE_MT_category_SH_NEW_INPUT, NODE_MT_category_SH_NEW_LAYOUT, NODE_MT_category_SH_NEW_OP_COLOR, NODE_MT_category_SH_NEW_OP_VECTOR, NODE_MT_category_SH_NEW_OUTPUT, NODE_MT_category_SH_NEW_SCRIPT, NODE_MT_category_SH_NEW_SHADER, NODE_MT_category_SH_NEW_TEXTURE, NODE_MT_category_SH_OP_COLOR, NODE_MT_category_SH_OP_VECTOR, NODE_MT_category_SH_OUTPUT, NODE_MT_category_TEX_CONVERTOR, NODE_MT_category_TEX_DISTORT, NODE_MT_category_TEX_GROUP, NODE_MT_category_TEX_INPUT, NODE_MT_category_TEX_LAYOUT, NODE_MT_category_TEX_OP_COLOR, NODE_MT_category_TEX_OUTPUT, NODE_MT_category_TEX_PATTERN, NODE_MT_category_TEX_TEXTURE, NODE_MT_node, NODE_MT_node_color_presets, NODE_MT_node_color_specials, NODE_MT_select, NODE_MT_view NODE_PT_active_node_color, NODE_PT_active_node_generic, NODE_PT_active_node_properties, NODE_PT_backdrop, NODE_PT_category_CMP_CONVERTOR, NODE_PT_category_CMP_DISTORT, NODE_PT_category_CMP_GROUP, NODE_PT_category_CMP_INPUT, NODE_PT_category_CMP_LAYOUT, NODE_PT_category_CMP_MATTE, NODE_PT_category_CMP_OP_COLOR, NODE_PT_category_CMP_OP_FILTER, NODE_PT_category_CMP_OP_VECTOR, NODE_PT_category_CMP_OUTPUT, NODE_PT_category_SH_CONVERTOR, NODE_PT_category_SH_GROUP, NODE_PT_category_SH_INPUT, NODE_PT_category_SH_LAYOUT, NODE_PT_category_SH_NEW_CONVERTOR, NODE_PT_category_SH_NEW_GROUP, NODE_PT_category_SH_NEW_INPUT, NODE_PT_category_SH_NEW_LAYOUT, NODE_PT_category_SH_NEW_OP_COLOR, NODE_PT_category_SH_NEW_OP_VECTOR, NODE_PT_category_SH_NEW_OUTPUT, NODE_PT_category_SH_NEW_SCRIPT, NODE_PT_category_SH_NEW_SHADER, NODE_PT_category_SH_NEW_TEXTURE, NODE_PT_category_SH_OP_COLOR, NODE_PT_category_SH_OP_VECTOR, NODE_PT_category_SH_OUTPUT, NODE_PT_category_TEX_CONVERTOR, NODE_PT_category_TEX_DISTORT, NODE_PT_category_TEX_GROUP, NODE_PT_category_TEX_INPUT, NODE_PT_category_TEX_LAYOUT, NODE_PT_category_TEX_OP_COLOR, NODE_PT_category_TEX_OUTPUT, NODE_PT_category_TEX_PATTERN, NODE_PT_category_TEX_TEXTURE, NODE_PT_quality
Object Properties OBJECT_PT_animation, OBJECT_PT_constraints, OBJECT_PT_context_object, OBJECT_PT_custom_props, OBJECT_PT_delta_transform, OBJECT_PT_display, OBJECT_PT_duplication, OBJECT_PT_groups, OBJECT_PT_motion_paths, OBJECT_PT_relations, OBJECT_PT_transform, OBJECT_PT_transform_locks
Outliner OUTLINER_HT_header OUTLINER_MT_edit_datablocks, OUTLINER_MT_search, OUTLINER_MT_view
Particle Properties PARTICLE_PT_boidbrain, PARTICLE_PT_cache, PARTICLE_PT_children, PARTICLE_PT_context_particles, PARTICLE_PT_custom_props, PARTICLE_PT_draw, PARTICLE_PT_emission, PARTICLE_PT_field_weights, PARTICLE_PT_force_fields, PARTICLE_PT_hair_dynamics, PARTICLE_PT_physics, PARTICLE_PT_render, PARTICLE_PT_rotation, PARTICLE_PT_velocity, PARTICLE_PT_vertexgroups
Physics Properties PHYSICS_PT_add, PHYSICS_PT_cloth, PHYSICS_PT_cloth_cache, PHYSICS_PT_cloth_collision, PHYSICS_PT_cloth_field_weights, PHYSICS_PT_cloth_stiffness, PHYSICS_PT_collision, PHYSICS_PT_domain_boundary, PHYSICS_PT_domain_gravity, PHYSICS_PT_domain_particles, PHYSICS_PT_dp_advanced_canvas, PHYSICS_PT_dp_brush_source, PHYSICS_PT_dp_brush_velocity, PHYSICS_PT_dp_brush_wave, PHYSICS_PT_dp_cache, PHYSICS_PT_dp_canvas_initial_color, PHYSICS_PT_dp_canvas_output, PHYSICS_PT_dp_effects, PHYSICS_PT_dynamic_paint, PHYSICS_PT_field, PHYSICS_PT_fluid, PHYSICS_PT_game_collision_bounds, PHYSICS_PT_game_obstacles, PHYSICS_PT_game_physics, PHYSICS_PT_rigid_body, PHYSICS_PT_rigid_body_collisions, PHYSICS_PT_rigid_body_constraint, PHYSICS_PT_rigid_body_dynamics, PHYSICS_PT_smoke, PHYSICS_PT_smoke_adaptive_domain, PHYSICS_PT_smoke_cache, PHYSICS_PT_smoke_field_weights, PHYSICS_PT_smoke_fire, PHYSICS_PT_smoke_flow_advanced, PHYSICS_PT_smoke_groups, PHYSICS_PT_smoke_highres, PHYSICS_PT_softbody, PHYSICS_PT_softbody_cache, PHYSICS_PT_softbody_collision, PHYSICS_PT_softbody_edge, PHYSICS_PT_softbody_field_weights, PHYSICS_PT_softbody_goal, PHYSICS_PT_softbody_solver
Properties Properties PROPERTIES_HT_header
Render Layer Properties RENDERLAYER_PT_freestyle, RENDERLAYER_PT_freestyle_lineset, RENDERLAYER_PT_freestyle_linestyle, RENDERLAYER_PT_layer_options, RENDERLAYER_PT_layer_passes, RENDERLAYER_PT_layers
Render Properties RENDER_MT_ffmpeg_presets, RENDER_MT_framerate_presets, RENDER_MT_lineset_specials, RENDER_MT_presets RENDER_PT_antialiasing, RENDER_PT_bake, RENDER_PT_dimensions, RENDER_PT_embedded, RENDER_PT_encoding, RENDER_PT_freestyle, RENDER_PT_game_display, RENDER_PT_game_player, RENDER_PT_game_shading, RENDER_PT_game_sound, RENDER_PT_game_stereo, RENDER_PT_game_system, RENDER_PT_motion_blur, RENDER_PT_output, RENDER_PT_performance, RENDER_PT_post_processing, RENDER_PT_render, RENDER_PT_shading, RENDER_PT_stamp
Scene Properties SCENE_PT_audio, SCENE_PT_color_management, SCENE_PT_custom_props, SCENE_PT_game_navmesh, SCENE_PT_keying_set_paths, SCENE_PT_keying_sets, SCENE_PT_physics, SCENE_PT_rigid_body_cache, SCENE_PT_rigid_body_field_weights, SCENE_PT_rigid_body_world, SCENE_PT_scene, SCENE_PT_simplify, SCENE_PT_unit
Sequencer Window SEQUENCER_HT_header SEQUENCER_MT_add, SEQUENCER_MT_add_effect, SEQUENCER_MT_marker, SEQUENCER_MT_select, SEQUENCER_MT_strip, SEQUENCER_MT_view, SEQUENCER_MT_view_toggle SEQUENCER_PT_edit, SEQUENCER_PT_effect, SEQUENCER_PT_filter, SEQUENCER_PT_input, SEQUENCER_PT_mask, SEQUENCER_PT_modifiers, SEQUENCER_PT_preview, SEQUENCER_PT_proxy, SEQUENCER_PT_scene, SEQUENCER_PT_sound, SEQUENCER_PT_view
Texture Properties TEXTURE_MT_envmap_specials, TEXTURE_MT_specials TEXTURE_PT_blend, TEXTURE_PT_clouds, TEXTURE_PT_colors, TEXTURE_PT_context_texture, TEXTURE_PT_custom_props, TEXTURE_PT_distortednoise, TEXTURE_PT_envmap, TEXTURE_PT_envmap_sampling, TEXTURE_PT_image, TEXTURE_PT_image_mapping, TEXTURE_PT_image_sampling, TEXTURE_PT_influence, TEXTURE_PT_magic, TEXTURE_PT_mapping, TEXTURE_PT_marble, TEXTURE_PT_musgrave, TEXTURE_PT_pointdensity, TEXTURE_PT_pointdensity_turbulence, TEXTURE_PT_preview, TEXTURE_PT_stucci, TEXTURE_PT_voronoi, TEXTURE_PT_voxeldata, TEXTURE_PT_wood
Text Editor TEXT_HT_header TEXT_MT_edit, TEXT_MT_edit_select, TEXT_MT_edit_to3d, TEXT_MT_format, TEXT_MT_templates, TEXT_MT_templates_osl, TEXT_MT_templates_py, TEXT_MT_text, TEXT_MT_toolbox, TEXT_MT_view TEXT_PT_find, TEXT_PT_properties
Timeline TIME_HT_header TIME_MT_autokey, TIME_MT_cache, TIME_MT_frame, TIME_MT_playback, TIME_MT_view
User Preferences USERPREF_HT_header USERPREF_MT_addons_dev_guides, USERPREF_MT_interaction_presets, USERPREF_MT_keyconfigs, USERPREF_MT_splash USERPREF_PT_addons, USERPREF_PT_edit, USERPREF_PT_file, USERPREF_PT_input, USERPREF_PT_interface, USERPREF_PT_system, USERPREF_PT_tabs, USERPREF_PT_theme
3D View VIEW3D_HT_header VIEW3D_MT_armature_specials, VIEW3D_MT_bone_options_disable, VIEW3D_MT_bone_options_enable, VIEW3D_MT_bone_options_toggle, VIEW3D_MT_brush, VIEW3D_MT_brush_paint_modes, VIEW3D_MT_edit_armature, VIEW3D_MT_edit_armature_parent, VIEW3D_MT_edit_armature_roll, VIEW3D_MT_edit_curve, VIEW3D_MT_edit_curve_ctrlpoints, VIEW3D_MT_edit_curve_segments, VIEW3D_MT_edit_curve_showhide, VIEW3D_MT_edit_curve_specials, VIEW3D_MT_edit_font, VIEW3D_MT_edit_lattice, VIEW3D_MT_edit_mesh, VIEW3D_MT_edit_mesh_clean, VIEW3D_MT_edit_mesh_delete, VIEW3D_MT_edit_mesh_edges, VIEW3D_MT_edit_mesh_extrude, VIEW3D_MT_edit_mesh_faces, VIEW3D_MT_edit_mesh_normals, VIEW3D_MT_edit_mesh_select_mode, VIEW3D_MT_edit_mesh_showhide, VIEW3D_MT_edit_mesh_specials, VIEW3D_MT_edit_mesh_vertices, VIEW3D_MT_edit_meta, VIEW3D_MT_edit_meta_showhide, VIEW3D_MT_edit_surface, VIEW3D_MT_edit_text_chars, VIEW3D_MT_hide_mask, VIEW3D_MT_hook, VIEW3D_MT_make_links, VIEW3D_MT_make_single_user, VIEW3D_MT_mirror, VIEW3D_MT_object, VIEW3D_MT_object_animation, VIEW3D_MT_object_apply, VIEW3D_MT_object_clear, VIEW3D_MT_object_constraints, VIEW3D_MT_object_game, VIEW3D_MT_object_group, VIEW3D_MT_object_parent, VIEW3D_MT_object_quick_effects, VIEW3D_MT_object_showhide, VIEW3D_MT_object_specials, VIEW3D_MT_object_track, VIEW3D_MT_paint_vertex, VIEW3D_MT_paint_weight, VIEW3D_MT_particle, VIEW3D_MT_particle_showhide, VIEW3D_MT_particle_specials, VIEW3D_MT_pose, VIEW3D_MT_pose_apply, VIEW3D_MT_pose_constraints, VIEW3D_MT_pose_group, VIEW3D_MT_pose_ik, VIEW3D_MT_pose_library, VIEW3D_MT_pose_motion, VIEW3D_MT_pose_propagate, VIEW3D_MT_pose_showhide, VIEW3D_MT_pose_slide, VIEW3D_MT_pose_specials, VIEW3D_MT_pose_transform, VIEW3D_MT_sculpt, VIEW3D_MT_select_edit_armature, VIEW3D_MT_select_edit_curve, VIEW3D_MT_select_edit_lattice, VIEW3D_MT_select_edit_mesh, VIEW3D_MT_select_edit_metaball, VIEW3D_MT_select_edit_surface, VIEW3D_MT_select_object, VIEW3D_MT_select_paint_mask, VIEW3D_MT_select_paint_mask_vertex, VIEW3D_MT_select_particle, VIEW3D_MT_select_pose, VIEW3D_MT_snap, VIEW3D_MT_tools_projectpaint_clone, VIEW3D_MT_tools_projectpaint_stencil, VIEW3D_MT_transform, VIEW3D_MT_transform_armature, VIEW3D_MT_transform_base, VIEW3D_MT_transform_object, VIEW3D_MT_uv_map, VIEW3D_MT_vertex_group, VIEW3D_MT_view, VIEW3D_MT_view_align, VIEW3D_MT_view_align_selected, VIEW3D_MT_view_cameras, VIEW3D_MT_view_navigation VIEW3D_PT_background_image, VIEW3D_PT_context_properties, VIEW3D_PT_etch_a_ton, VIEW3D_PT_sculpt_options, VIEW3D_PT_sculpt_symmetry, VIEW3D_PT_sculpt_topology, VIEW3D_PT_tools_armatureedit, VIEW3D_PT_tools_armatureedit_options, VIEW3D_PT_tools_brush, VIEW3D_PT_tools_brush_appearance, VIEW3D_PT_tools_brush_curve, VIEW3D_PT_tools_brush_stroke, VIEW3D_PT_tools_brush_texture, VIEW3D_PT_tools_curveedit, VIEW3D_PT_tools_latticeedit, VIEW3D_PT_tools_mask_texture, VIEW3D_PT_tools_mballedit, VIEW3D_PT_tools_meshedit, VIEW3D_PT_tools_meshedit_options, VIEW3D_PT_tools_objectmode, VIEW3D_PT_tools_particlemode, VIEW3D_PT_tools_posemode, VIEW3D_PT_tools_posemode_options, VIEW3D_PT_tools_projectpaint, VIEW3D_PT_tools_rigidbody, VIEW3D_PT_tools_surfaceedit, VIEW3D_PT_tools_textedit, VIEW3D_PT_tools_vertexpaint, VIEW3D_PT_tools_weightpaint, VIEW3D_PT_tools_weightpaint_options, VIEW3D_PT_transform_orientations, VIEW3D_PT_view3d_cursor, VIEW3D_PT_view3d_curvedisplay, VIEW3D_PT_view3d_display, VIEW3D_PT_view3d_meshdisplay, VIEW3D_PT_view3d_meshstatvis, VIEW3D_PT_view3d_motion_tracking, VIEW3D_PT_view3d_name, VIEW3D_PT_view3d_properties
Window Manager Properties WM_MT_operator_presets
World Properties WORLD_PT_ambient_occlusion, WORLD_PT_context_world, WORLD_PT_custom_props, WORLD_PT_environment_lighting, WORLD_PT_game_context_world, WORLD_PT_game_mist, WORLD_PT_game_physics, WORLD_PT_game_world, WORLD_PT_gather, WORLD_PT_indirect_lighting, WORLD_PT_mist, WORLD_PT_preview, WORLD_PT_stars, WORLD_PT_world