Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrecht Van Lommel <brechtvanlommel@pandora.be>2013-04-30 14:32:02 +0400
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2013-04-30 14:32:02 +0400
commit3b04b861bd964a54ee88defe899978ae564cb037 (patch)
tree1b30114cefe34686bb870f97eced701c96b381b9 /release
parent9461af89f1da9d4d1f4eef952084bbc7711376d7 (diff)
Fix another part of #35141: there was no way to reset the stencil transform after e.g.
scaling it along one axis, now there's a Reset Transform button. The Image Aspect button is now also hidden unless the texture is an image texture. And also hide the color wheel for painting tools that don't use colors.
Diffstat (limited to 'release')
-rw-r--r--release/scripts/startup/bl_ui/properties_paint_common.py8
-rw-r--r--release/scripts/startup/bl_ui/space_image.py6
2 files changed, 10 insertions, 4 deletions
diff --git a/release/scripts/startup/bl_ui/properties_paint_common.py b/release/scripts/startup/bl_ui/properties_paint_common.py
index 56b82655e47..1b6356f0dba 100644
--- a/release/scripts/startup/bl_ui/properties_paint_common.py
+++ b/release/scripts/startup/bl_ui/properties_paint_common.py
@@ -84,7 +84,9 @@ def brush_texture_settings(layout, brush, sculpt):
layout.separator()
if tex_slot.map_mode == 'STENCIL':
- layout.operator("brush.stencil_fit_image_aspect")
+ if brush.texture and brush.texture.type == 'IMAGE':
+ layout.operator("brush.stencil_fit_image_aspect")
+ layout.operator("brush.stencil_reset_transform")
# angle and texture_angle_source
col = layout.column()
@@ -127,7 +129,9 @@ def brush_mask_texture_settings(layout, brush):
layout.separator()
if mask_tex_slot.map_mode == 'STENCIL':
- layout.operator("brush.stencil_fit_image_aspect").mask = True
+ if brush.mask_texture and brush.mask_texture.type == 'IMAGE':
+ layout.operator("brush.stencil_fit_image_aspect").mask = True
+ layout.operator("brush.stencil_reset_transform")
if brush.mask_texture:
layout.label(text="Mask Mapping:")
diff --git a/release/scripts/startup/bl_ui/space_image.py b/release/scripts/startup/bl_ui/space_image.py
index 3acab7200ea..458266aec46 100644
--- a/release/scripts/startup/bl_ui/space_image.py
+++ b/release/scripts/startup/bl_ui/space_image.py
@@ -696,8 +696,10 @@ class IMAGE_PT_paint(Panel, ImagePaintPanel):
if brush:
col = layout.column()
- col.template_color_picker(brush, "color", value_slider=True)
- col.prop(brush, "color", text="")
+
+ if brush.image_tool == 'DRAW' and brush.blend not in ('ERASE_ALPHA', 'ADD_ALPHA'):
+ col.template_color_picker(brush, "color", value_slider=True)
+ col.prop(brush, "color", text="")
row = col.row(align=True)
self.prop_unified_size(row, context, brush, "size", slider=True, text="Radius")