[Bf-blender-cvs] [1de83743749] master: UI: Remove extra padding on Annotate tool settings

Dalai Felinto noreply at git.blender.org
Wed Oct 20 19:02:04 CEST 2021


Commit: 1de837437498f25997fa69df152529fe92a51f5c
Author: Dalai Felinto
Date:   Wed Oct 20 17:53:03 2021 +0200
Branches: master
https://developer.blender.org/rB1de837437498f25997fa69df152529fe92a51f5c

UI: Remove extra padding on Annotate tool settings

For some reason the Annotate tool has an extra padding when compared to
other tools. This makes the UI to flicker a bit (specially with D12939
applied).

Differential Revision: https://developer.blender.org/D12943

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

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

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

diff --git a/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py b/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py
index 9b1b401bc5b..721c6bdb99c 100644
--- a/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py
+++ b/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py
@@ -185,23 +185,18 @@ class _defs_annotate:
         tool_settings = context.tool_settings
 
         if space_type == 'VIEW_3D':
-            layout.separator()
-
             row = layout.row(align=True)
             row.prop(tool_settings, "annotation_stroke_placement_view3d", text="Placement")
             if tool_settings.gpencil_stroke_placement_view3d == 'CURSOR':
                 row.prop(tool_settings.gpencil_sculpt, "lockaxis")
             elif tool_settings.gpencil_stroke_placement_view3d in {'SURFACE', 'STROKE'}:
                 row.prop(tool_settings, "use_gpencil_stroke_endpoints")
-        elif space_type in {'IMAGE_EDITOR', 'NODE_EDITOR', 'SEQUENCE_EDITOR', 'CLIP_EDITOR'}:
-            layout.separator()
 
+        elif space_type in {'IMAGE_EDITOR', 'NODE_EDITOR', 'SEQUENCE_EDITOR', 'CLIP_EDITOR'}:
             row = layout.row(align=True)
             row.prop(tool_settings, "annotation_stroke_placement_view2d", text="Placement")
 
         if tool.idname == "builtin.annotate_line":
-            layout.separator()
-
             props = tool.operator_properties("gpencil.annotate")
             if region_type == 'TOOL_HEADER':
                 row = layout.row()
@@ -223,7 +218,6 @@ class _defs_annotate:
                 subrow.prop(props, "stabilizer_radius", text="Radius", slider=True)
                 subrow.prop(props, "stabilizer_factor", text="Factor", slider=True)
             else:
-                layout.separator()
                 layout.prop(props, "use_stabilizer", text="Stabilize Stroke")
                 col = layout.column(align=False)
                 col.active = props.use_stabilizer



More information about the Bf-blender-cvs mailing list