Changeset View
Changeset View
Standalone View
Standalone View
release/scripts/startup/bl_ui/space_view3d.py
- This file is larger than 256 KB, so syntax highlighting is disabled by default.
| Show First 20 Lines • Show All 2,206 Lines • ▼ Show 20 Lines | def draw(self, _context): | ||||
| layout = self.layout | layout = self.layout | ||||
| layout.operator_context = 'EXEC_REGION_WIN' | layout.operator_context = 'EXEC_REGION_WIN' | ||||
| layout.operator("object.armature_add", text="Single Bone", icon='BONE_DATA') | layout.operator("object.armature_add", text="Single Bone", icon='BONE_DATA') | ||||
| class VIEW3D_MT_light_add(Menu): | class VIEW3D_MT_light_add(Menu): | ||||
| bl_idname = "VIEW3D_MT_light_add" | bl_idname = "VIEW3D_MT_light_add" | ||||
| bl_context = i18n_contexts.id_light | |||||
| bl_label = "Light" | bl_label = "Light" | ||||
| def draw(self, _context): | def draw(self, _context): | ||||
| layout = self.layout | layout = self.layout | ||||
| layout.operator_context = 'INVOKE_REGION_WIN' | layout.operator_context = 'INVOKE_REGION_WIN' | ||||
| layout.operator_enum("object.light_add", "type") | layout.operator_enum("object.light_add", "type") | ||||
| Show All 21 Lines | |||||
| class VIEW3D_MT_volume_add(Menu): | class VIEW3D_MT_volume_add(Menu): | ||||
| bl_idname = "VIEW3D_MT_volume_add" | bl_idname = "VIEW3D_MT_volume_add" | ||||
| bl_label = "Volume" | bl_label = "Volume" | ||||
| def draw(self, _context): | def draw(self, _context): | ||||
| layout = self.layout | layout = self.layout | ||||
| layout.operator("object.volume_import", text="Import OpenVDB...", icon='OUTLINER_DATA_VOLUME') | layout.operator("object.volume_import", text="Import OpenVDB...", icon='OUTLINER_DATA_VOLUME') | ||||
| layout.operator("object.volume_add", text="Empty", icon='OUTLINER_DATA_VOLUME') | layout.operator("object.volume_add", text="Empty", | ||||
| text_ctxt=i18n_contexts.id_volume, | |||||
| icon='OUTLINER_DATA_VOLUME') | |||||
| class VIEW3D_MT_add(Menu): | class VIEW3D_MT_add(Menu): | ||||
| bl_label = "Add" | bl_label = "Add" | ||||
| bl_translation_context = i18n_contexts.operator_default | bl_translation_context = i18n_contexts.operator_default | ||||
| def draw(self, context): | def draw(self, context): | ||||
| layout = self.layout | layout = self.layout | ||||
| Show All 24 Lines | def draw(self, context): | ||||
| layout.menu("VIEW3D_MT_armature_add", icon='OUTLINER_OB_ARMATURE') | layout.menu("VIEW3D_MT_armature_add", icon='OUTLINER_OB_ARMATURE') | ||||
| else: | else: | ||||
| layout.operator("object.armature_add", text="Armature", icon='OUTLINER_OB_ARMATURE') | layout.operator("object.armature_add", text="Armature", icon='OUTLINER_OB_ARMATURE') | ||||
| layout.operator("object.add", text="Lattice", icon='OUTLINER_OB_LATTICE').type = 'LATTICE' | layout.operator("object.add", text="Lattice", icon='OUTLINER_OB_LATTICE').type = 'LATTICE' | ||||
| layout.separator() | layout.separator() | ||||
| layout.operator_menu_enum("object.empty_add", "type", text="Empty", icon='OUTLINER_OB_EMPTY') | layout.operator_menu_enum("object.empty_add", "type", text="Empty", | ||||
| text_ctxt=i18n_contexts.id_id, | |||||
| icon='OUTLINER_OB_EMPTY') | |||||
| layout.menu("VIEW3D_MT_image_add", text="Image", icon='OUTLINER_OB_IMAGE') | layout.menu("VIEW3D_MT_image_add", text="Image", icon='OUTLINER_OB_IMAGE') | ||||
| layout.separator() | layout.separator() | ||||
| layout.menu("VIEW3D_MT_light_add", icon='OUTLINER_OB_LIGHT') | layout.menu("VIEW3D_MT_light_add", icon='OUTLINER_OB_LIGHT') | ||||
| layout.menu("VIEW3D_MT_lightprobe_add", icon='OUTLINER_OB_LIGHTPROBE') | layout.menu("VIEW3D_MT_lightprobe_add", icon='OUTLINER_OB_LIGHTPROBE') | ||||
| layout.separator() | layout.separator() | ||||
| ▲ Show 20 Lines • Show All 5,727 Lines • Show Last 20 Lines | |||||