[Bf-blender-cvs] [b350b194eb2] blender2.8: GP: Change direction text depending of sculpt brush

Antonioya noreply at git.blender.org
Sat Sep 22 16:27:11 CEST 2018


Commit: b350b194eb2dc49acdc15acfe2ea15dd53baf25b
Author: Antonioya
Date:   Sat Sep 22 16:26:52 2018 +0200
Branches: blender2.8
https://developer.blender.org/rBb350b194eb2dc49acdc15acfe2ea15dd53baf25b

GP: Change direction text depending of sculpt brush

===================================================================

M	release/scripts/startup/bl_ui/properties_grease_pencil_common.py

===================================================================

diff --git a/release/scripts/startup/bl_ui/properties_grease_pencil_common.py b/release/scripts/startup/bl_ui/properties_grease_pencil_common.py
index 29f61ff0aae..760c5f8e259 100644
--- a/release/scripts/startup/bl_ui/properties_grease_pencil_common.py
+++ b/release/scripts/startup/bl_ui/properties_grease_pencil_common.py
@@ -259,10 +259,17 @@ class GreasePencilStrokeSculptPanel:
 
         layout.prop(brush, "use_falloff")
 
-        if tool in {'THICKNESS', 'STRENGTH', 'PINCH', 'TWIST'}:
-            col = layout.column()
-            col.separator()
-            col.row().prop(brush, "direction", expand=True)
+        layout.use_property_split = False
+        if tool in {'THICKNESS', 'STRENGTH'}:
+            layout.row().prop(brush, "direction", expand=True)
+        elif tool == 'PINCH':
+            row = layout.row(align=True)
+            row.prop_enum(brush, "direction",  value='ADD', text="Pinch")
+            row.prop_enum(brush, "direction",  value='SUBTRACT', text="Inflate")
+        elif settings.tool == 'TWIST':
+            row = layout.row(align=True)
+            row.prop_enum(brush, "direction",  value='ADD', text="CCW")
+            row.prop_enum(brush, "direction",  value='SUBTRACT', text="CW")
 
 
 class GreasePencilSculptOptionsPanel:



More information about the Bf-blender-cvs mailing list