From 8dd72c476e51ee457fdd98625eff7a1afc88f49e Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Mon, 18 Jul 2011 05:41:46 +0000 Subject: fix [#28005] Python Add-Ons are constantly reloaded if twice in the path Addons are checked for their timestamps and reloaded when it changes but this failed when, 2 addons had the same name since different times caused 2 reloads on every redraw. Now when duplicate addons are in the path now give a error message in the UI and print path conflict in the console and don't thrash reloading. --- release/scripts/startup/bl_ui/space_userpref.py | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'release/scripts/startup/bl_ui') diff --git a/release/scripts/startup/bl_ui/space_userpref.py b/release/scripts/startup/bl_ui/space_userpref.py index 6a809aefb9d..139b3205835 100644 --- a/release/scripts/startup/bl_ui/space_userpref.py +++ b/release/scripts/startup/bl_ui/space_userpref.py @@ -889,6 +889,16 @@ class USERPREF_PT_addons(bpy.types.Panel): return True return False + @staticmethod + def draw_error(layout, message): + lines = message.split("\n") + box = layout.box() + rowsub = box.row() + rowsub.label(lines[0]) + rowsub.label(icon='ERROR') + for l in lines[1:]: + box.label(l) + def draw(self, context): layout = self.layout @@ -909,6 +919,14 @@ class USERPREF_PT_addons(bpy.types.Panel): col = split.column() + # set in addon_utils.modules(...) + if addon_utils.error_duplicates: + self.draw_error(col, + "Multiple addons using the same name found!\n" + "likely a problem with the script search path.\n" + "(see console for details)", + ) + filter = context.window_manager.addon_filter search = context.window_manager.addon_search.lower() support = context.window_manager.addon_support -- cgit v1.2.3 From 4024b14b43c6409a319d80611bcf8b5e536bda1f Mon Sep 17 00:00:00 2001 From: Jeroen Bakker Date: Tue, 19 Jul 2011 08:31:53 +0000 Subject: fix for [#28012] Mat ID messy with shader nodes Issue was that the Shader tree execution changed the ShaderInput. Changes are that the UI is updated that only the main material will have the pass_index this is displayed in the "render pipeline options" panel. When the material is not a node material the pass_index will be shown at the "options" panel To test enable nodes on the material Add a new input material change the pass_index of the material (render pipeline options) Enable RenderPass material ID and use the compositor to read out the material pass Jeroen --- release/scripts/startup/bl_ui/properties_material.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'release/scripts/startup/bl_ui') diff --git a/release/scripts/startup/bl_ui/properties_material.py b/release/scripts/startup/bl_ui/properties_material.py index 45c15bd1ce6..2a52ae23782 100644 --- a/release/scripts/startup/bl_ui/properties_material.py +++ b/release/scripts/startup/bl_ui/properties_material.py @@ -174,6 +174,7 @@ class MATERIAL_PT_pipeline(MaterialButtonsPanel, bpy.types.Panel): row.prop(mat, "use_transparency") sub = row.column() sub.prop(mat, "offset_z") + sub.active = mat_type and mat.use_transparency and mat.transparency_method == 'Z_TRANSPARENCY' row = layout.row() @@ -199,6 +200,7 @@ class MATERIAL_PT_pipeline(MaterialButtonsPanel, bpy.types.Panel): col.prop(mat, "shadow_cast_alpha", text="Casting Alpha") col.prop(mat, "use_cast_buffer_shadows") col.prop(mat, "use_cast_approximate") + col.prop(mat, "pass_index") class MATERIAL_PT_diffuse(MaterialButtonsPanel, bpy.types.Panel): @@ -729,7 +731,8 @@ class MATERIAL_PT_options(MaterialButtonsPanel, bpy.types.Panel): col.prop(mat, "use_vertex_color_paint") col.prop(mat, "use_vertex_color_light") col.prop(mat, "use_object_color") - col.prop(mat, "pass_index") + if simple_material(base_mat): + col.prop(mat, "pass_index") class MATERIAL_PT_shadow(MaterialButtonsPanel, bpy.types.Panel): -- cgit v1.2.3 From 2c798fd86d9a9aed1c2459f5550bacb03d583f96 Mon Sep 17 00:00:00 2001 From: Daniel Salazar Date: Thu, 21 Jul 2011 21:34:08 +0000 Subject: Adding Shear transform to UV menu and Ctrl Alt Shift S hotkey (same as in 3D View) --- release/scripts/startup/bl_ui/space_image.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'release/scripts/startup/bl_ui') diff --git a/release/scripts/startup/bl_ui/space_image.py b/release/scripts/startup/bl_ui/space_image.py index 722b46aba11..fa5579ea2e0 100644 --- a/release/scripts/startup/bl_ui/space_image.py +++ b/release/scripts/startup/bl_ui/space_image.py @@ -198,6 +198,10 @@ class IMAGE_MT_uvs_transform(bpy.types.Menu): layout.operator("transform.rotate") layout.operator("transform.resize") + layout.separator() + + layout.operator("transform.shear") + class IMAGE_MT_uvs_snap(bpy.types.Menu): bl_label = "Snap" -- cgit v1.2.3 From 8cbd88aeef2ece7fc1c436db5284ac115b230c57 Mon Sep 17 00:00:00 2001 From: Thomas Dinges Date: Sat, 23 Jul 2011 15:36:51 +0000 Subject: 2.5 UI: * Added back icon to open the Splash Screen in the info header, next to version string info. * Removed an unnecessary toggle argument for particle mode select buttons. The Toggle argument is only intended for booleans, not enums. --- release/scripts/startup/bl_ui/space_info.py | 6 ++++-- release/scripts/startup/bl_ui/space_view3d.py | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) (limited to 'release/scripts/startup/bl_ui') diff --git a/release/scripts/startup/bl_ui/space_info.py b/release/scripts/startup/bl_ui/space_info.py index 2b12e75564c..cda37b3119a 100644 --- a/release/scripts/startup/bl_ui/space_info.py +++ b/release/scripts/startup/bl_ui/space_info.py @@ -60,8 +60,10 @@ class INFO_HT_header(bpy.types.Header): layout.template_running_jobs() layout.template_reports_banner() - - layout.label(text=scene.statistics()) + + row = layout.row(align=True) + row.operator("wm.splash", text="", icon='BLENDER', emboss=False) + row.label(text=scene.statistics()) # XXX: this should be right-aligned to the RHS of the region layout.operator("wm.window_fullscreen_toggle", icon='FULLSCREEN_ENTER', text="") diff --git a/release/scripts/startup/bl_ui/space_view3d.py b/release/scripts/startup/bl_ui/space_view3d.py index aef6accb4e1..b5e813d16e7 100644 --- a/release/scripts/startup/bl_ui/space_view3d.py +++ b/release/scripts/startup/bl_ui/space_view3d.py @@ -68,7 +68,7 @@ class VIEW3D_HT_header(bpy.types.Header): if obj: # Particle edit if obj.mode == 'PARTICLE_EDIT': - row.prop(toolsettings.particle_edit, "select_mode", text="", expand=True, toggle=True) + row.prop(toolsettings.particle_edit, "select_mode", text="", expand=True) # Occlude geometry if view.viewport_shade in {'SOLID', 'SHADED', 'TEXTURED'} and (obj.mode == 'PARTICLE_EDIT' or (obj.mode == 'EDIT' and obj.type == 'MESH')): -- cgit v1.2.3 From 43994ce213d43ecc4448493a8920b1a9e7f34492 Mon Sep 17 00:00:00 2001 From: Thomas Dinges Date: Sat, 23 Jul 2011 22:08:37 +0000 Subject: 2.5: * Removed some old not used code. --- release/scripts/startup/bl_ui/space_view3d.py | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) (limited to 'release/scripts/startup/bl_ui') diff --git a/release/scripts/startup/bl_ui/space_view3d.py b/release/scripts/startup/bl_ui/space_view3d.py index b5e813d16e7..7d35ca9ddb8 100644 --- a/release/scripts/startup/bl_ui/space_view3d.py +++ b/release/scripts/startup/bl_ui/space_view3d.py @@ -54,16 +54,8 @@ class VIEW3D_HT_header(bpy.types.Header): sub.menu("VIEW3D_MT_object") row = layout.row() - row.template_header_3D() - - # do in C for now since these buttons cant be both toggle AND exclusive. - ''' - if obj and obj.mode == 'EDIT' and obj.type == 'MESH': - row_sub = row.row(align=True) - row_sub.prop(toolsettings, "mesh_select_mode", text="", index=0, icon='VERTEXSEL') - row_sub.prop(toolsettings, "mesh_select_mode", text="", index=1, icon='EDGESEL') - row_sub.prop(toolsettings, "mesh_select_mode", text="", index=2, icon='FACESEL') - ''' + # Contains buttons like Mode, Pivot, Manipulator, Layer, Mesh Select Mode... + row.template_header_3D() if obj: # Particle edit -- cgit v1.2.3 From cb2423e849d03cf1d288df94401cfd8d49c8ff56 Mon Sep 17 00:00:00 2001 From: Daniel Salazar Date: Sun, 24 Jul 2011 00:59:03 +0000 Subject: Add Push/Pull to toolbar --- release/scripts/startup/bl_ui/space_view3d_toolbar.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'release/scripts/startup/bl_ui') diff --git a/release/scripts/startup/bl_ui/space_view3d_toolbar.py b/release/scripts/startup/bl_ui/space_view3d_toolbar.py index e1efeed87ea..19c3224f138 100644 --- a/release/scripts/startup/bl_ui/space_view3d_toolbar.py +++ b/release/scripts/startup/bl_ui/space_view3d_toolbar.py @@ -116,7 +116,8 @@ class VIEW3D_PT_tools_meshedit(View3DPanel, bpy.types.Panel): col.operator("transform.translate") col.operator("transform.rotate") col.operator("transform.resize", text="Scale") - col.operator("transform.shrink_fatten", text="Along Normal") + col.operator("transform.shrink_fatten", text="Shrink/Fatten") + col.operator("transform.push_pull", text="Push/Pull") col = layout.column(align=True) col.label(text="Deform:") -- cgit v1.2.3 From 4ab7c6ae1a6d9867d30d5eb960aece38bb0233f7 Mon Sep 17 00:00:00 2001 From: Thomas Dinges Date: Sun, 24 Jul 2011 11:24:30 +0000 Subject: 2.5 World Buttons: * Exposure and Color Range buttons were missing, added them back. --- release/scripts/startup/bl_ui/properties_world.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'release/scripts/startup/bl_ui') diff --git a/release/scripts/startup/bl_ui/properties_world.py b/release/scripts/startup/bl_ui/properties_world.py index 4f398c9fbd9..0272667e754 100644 --- a/release/scripts/startup/bl_ui/properties_world.py +++ b/release/scripts/startup/bl_ui/properties_world.py @@ -20,8 +20,6 @@ import bpy from rna_prop_ui import PropertyPanel -# TODO, "color_range" not in the UI - class WorldButtonsPanel(): bl_space_type = 'PROPERTIES' @@ -95,6 +93,10 @@ class WORLD_PT_world(WorldButtonsPanel, bpy.types.Panel): col.prop(world, "zenith_color") col.active = world.use_sky_blend row.column().prop(world, "ambient_color") + + row = layout.row() + row.prop(world, "exposure") + row.prop(world, "color_range") class WORLD_PT_ambient_occlusion(WorldButtonsPanel, bpy.types.Panel): -- cgit v1.2.3 From 71692e802fc50ad9dd76659d2868843e708dbd40 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Tue, 26 Jul 2011 07:39:00 +0000 Subject: py api: - added menu templates - move template menu into the header of the text editor (so users will find more easily) - updated mathutils examples, switching the order of multiplication. --- release/scripts/startup/bl_ui/space_text.py | 43 +++++++++++++++++------------ 1 file changed, 26 insertions(+), 17 deletions(-) (limited to 'release/scripts/startup/bl_ui') diff --git a/release/scripts/startup/bl_ui/space_text.py b/release/scripts/startup/bl_ui/space_text.py index 0fc8d937f66..582c9442a4a 100644 --- a/release/scripts/startup/bl_ui/space_text.py +++ b/release/scripts/startup/bl_ui/space_text.py @@ -16,7 +16,7 @@ # # ##### END GPL LICENSE BLOCK ##### -# +# import bpy @@ -36,10 +36,13 @@ class TEXT_HT_header(bpy.types.Header): sub = row.row(align=True) sub.menu("TEXT_MT_view") sub.menu("TEXT_MT_text") + if text: sub.menu("TEXT_MT_edit") sub.menu("TEXT_MT_format") + sub.menu("TEXT_MT_templates") + if text and text.is_modified: row = layout.row() row.alert = True @@ -63,11 +66,13 @@ class TEXT_HT_header(bpy.types.Header): row = layout.row() if text.filepath: if text.is_dirty: - row.label(text="File: *%s (unsaved)" % text.filepath) + row.label(text="File: *%r (unsaved)" % text.filepath) else: - row.label(text="File: %s" % text.filepath) + row.label(text="File: %r" % text.filepath) else: - row.label(text="Text: External" if text.library else "Text: Internal") + row.label(text="Text: External" + if text.library + else "Text: Internal") class TEXT_PT_properties(bpy.types.Panel): @@ -150,8 +155,12 @@ class TEXT_MT_view(bpy.types.Menu): layout.separator() - layout.operator("text.move", text="Top of File").type = 'FILE_TOP' - layout.operator("text.move", text="Bottom of File").type = 'FILE_BOTTOM' + layout.operator("text.move", + text="Top of File", + ).type = 'FILE_TOP' + layout.operator("text.move", + text="Bottom of File", + ).type = 'FILE_BOTTOM' class TEXT_MT_text(bpy.types.Menu): @@ -185,19 +194,15 @@ class TEXT_MT_text(bpy.types.Menu): # XXX uiMenuItemO(head, 0, "text.refresh_pyconstraints"); #endif - layout.separator() - - layout.menu("TEXT_MT_templates") - class TEXT_MT_templates(bpy.types.Menu): - ''' - Creates the menu items by scanning scripts/templates - ''' - bl_label = "Script Templates" + bl_label = "Templates" def draw(self, context): - self.path_menu(bpy.utils.script_paths("templates"), "text.open", {"internal": True}) + self.path_menu(bpy.utils.script_paths("templates"), + "text.open", + {"internal": True}, + ) class TEXT_MT_edit_select(bpy.types.Menu): @@ -246,8 +251,12 @@ class TEXT_MT_edit_to3d(bpy.types.Menu): def draw(self, context): layout = self.layout - layout.operator("text.to_3d_object", text="One Object").split_lines = False - layout.operator("text.to_3d_object", text="One Object Per Line").split_lines = True + layout.operator("text.to_3d_object", + text="One Object", + ).split_lines = False + layout.operator("text.to_3d_object", + text="One Object Per Line", + ).split_lines = True class TEXT_MT_edit(bpy.types.Menu): -- cgit v1.2.3 From 9a250bea61340cb8b3625345df6560ba3e7b878f Mon Sep 17 00:00:00 2001 From: Thomas Dinges Date: Tue, 26 Jul 2011 20:05:17 +0000 Subject: Fix part of [#28088] bad button spacing with layout engine for menu items. * Fixed a cut off text. * small cleanup --- release/scripts/startup/bl_ui/space_text.py | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) (limited to 'release/scripts/startup/bl_ui') diff --git a/release/scripts/startup/bl_ui/space_text.py b/release/scripts/startup/bl_ui/space_text.py index 582c9442a4a..b787fc5cf75 100644 --- a/release/scripts/startup/bl_ui/space_text.py +++ b/release/scripts/startup/bl_ui/space_text.py @@ -33,22 +33,21 @@ class TEXT_HT_header(bpy.types.Header): row.template_header() if context.area.show_menus: - sub = row.row(align=True) - sub.menu("TEXT_MT_view") - sub.menu("TEXT_MT_text") + row.menu("TEXT_MT_view") + row.menu("TEXT_MT_text") if text: - sub.menu("TEXT_MT_edit") - sub.menu("TEXT_MT_format") + row.menu("TEXT_MT_edit") + row.menu("TEXT_MT_format") - sub.menu("TEXT_MT_templates") + row.menu("TEXT_MT_templates") if text and text.is_modified: - row = layout.row() - row.alert = True - row.operator("text.resolve_conflict", text="", icon='HELP') + sub = row.row() + sub.alert = True + sub.operator("text.resolve_conflict", text="", icon='HELP') - layout.template_ID(st, "text", new="text.new", unlink="text.unlink") + row.template_ID(st, "text", new="text.new", unlink="text.unlink") row = layout.row(align=True) row.prop(st, "show_line_numbers", text="") -- cgit v1.2.3 From 46cea372669f25b691fd90dc792a1fee33e36887 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Wed, 27 Jul 2011 07:22:31 +0000 Subject: fix [#28066] Unchecking 'self project' messes up 'Snap to Vertex' this option is useful for all non-grid snapping modes (when in editmode) so make available in those cases too. --- release/scripts/startup/bl_ui/space_view3d.py | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) (limited to 'release/scripts/startup/bl_ui') diff --git a/release/scripts/startup/bl_ui/space_view3d.py b/release/scripts/startup/bl_ui/space_view3d.py index 7d35ca9ddb8..acb0499c40f 100644 --- a/release/scripts/startup/bl_ui/space_view3d.py +++ b/release/scripts/startup/bl_ui/space_view3d.py @@ -79,19 +79,22 @@ class VIEW3D_HT_header(bpy.types.Header): row.prop(toolsettings, "proportional_edit_falloff", text="", icon_only=True) # Snap + snap_element = toolsettings.snap_element row = layout.row(align=True) row.prop(toolsettings, "use_snap", text="") row.prop(toolsettings, "snap_element", text="", icon_only=True) - if toolsettings.snap_element != 'INCREMENT': + if snap_element != 'INCREMENT': row.prop(toolsettings, "snap_target", text="") - if obj and obj.mode == 'OBJECT': - row.prop(toolsettings, "use_snap_align_rotation", text="") - if toolsettings.snap_element == 'VOLUME': + if obj: + if obj.mode == 'OBJECT': + row.prop(toolsettings, "use_snap_align_rotation", text="") + elif obj.mode == 'EDIT': + row.prop(toolsettings, "use_snap_self", text="") + + if snap_element == 'VOLUME': row.prop(toolsettings, "use_snap_peel_object", text="") - elif toolsettings.snap_element == 'FACE': + elif snap_element == 'FACE': row.prop(toolsettings, "use_snap_project", text="") - if toolsettings.use_snap_project and obj.mode == 'EDIT': - row.prop(toolsettings, "use_snap_project_self", text="") # OpenGL render row = layout.row(align=True) -- cgit v1.2.3 From 2dc826f083c2209aab83981a8d1dc39c621e0841 Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Thu, 28 Jul 2011 11:16:10 +0000 Subject: New option for multires modifier: Subdivide UVs Enabled by default and also enabled for older filesm so there should be no regressions. In some cases it's useful to not use subdivided uvs for multires. --- release/scripts/startup/bl_ui/properties_data_modifier.py | 1 + 1 file changed, 1 insertion(+) (limited to 'release/scripts/startup/bl_ui') diff --git a/release/scripts/startup/bl_ui/properties_data_modifier.py b/release/scripts/startup/bl_ui/properties_data_modifier.py index ce6d0990f05..0a4d0b60514 100644 --- a/release/scripts/startup/bl_ui/properties_data_modifier.py +++ b/release/scripts/startup/bl_ui/properties_data_modifier.py @@ -394,6 +394,7 @@ class DATA_PT_modifiers(ModifierButtonsPanel, bpy.types.Panel): col.operator("object.multires_higher_levels_delete", text="Delete Higher") col.operator("object.multires_reshape", text="Reshape") col.operator("object.multires_base_apply", text="Apply Base") + col.prop(md, "use_subsurf_uv") col.prop(md, "show_only_control_edges") layout.separator() -- cgit v1.2.3