[Bf-blender-cvs] [a25cfc5db26] master: Texture/Vertex Paint: Add secondary color to the tool header

Sebastian Parborg noreply at git.blender.org
Mon Jan 17 16:50:29 CET 2022


Commit: a25cfc5db2625d147c4f2d89584e6d87748a47bb
Author: Sebastian Parborg
Date:   Mon Jan 17 16:48:18 2022 +0100
Branches: master
https://developer.blender.org/rBa25cfc5db2625d147c4f2d89584e6d87748a47bb

Texture/Vertex Paint: Add secondary color to the tool header

Before we would only display the secondary color in the N-panel.
Now we also display it in the tool header.

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

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

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

diff --git a/release/scripts/startup/bl_ui/properties_paint_common.py b/release/scripts/startup/bl_ui/properties_paint_common.py
index 49effabc5cf..347f771d1f6 100644
--- a/release/scripts/startup/bl_ui/properties_paint_common.py
+++ b/release/scripts/startup/bl_ui/properties_paint_common.py
@@ -1107,7 +1107,11 @@ def brush_basic_texpaint_settings(layout, context, brush, *, compact=False):
     capabilities = brush.image_paint_capabilities
 
     if capabilities.has_color:
-        UnifiedPaintPanel.prop_unified_color(layout, context, brush, "color", text="")
+        row = layout.row(align=True)
+        row.ui_units_x = 4
+        UnifiedPaintPanel.prop_unified_color(row, context, brush, "color", text="")
+        UnifiedPaintPanel.prop_unified_color(row, context, brush, "secondary_color", text="")
+        row.separator()
         layout.prop(brush, "blend", text="" if compact else "Blend")
 
     UnifiedPaintPanel.prop_unified(



More information about the Bf-blender-cvs mailing list