Browse Source

Fixed missing fill and updated color picker

Krzysztof Krysiński 5 months ago
parent
commit
dfc04cdd8d

+ 2 - 2
src/PixiEditor/Models/DocumentModels/UpdateableChangeExecutors/DrawableShapeToolExecutor.cs

@@ -25,7 +25,7 @@ internal abstract class DrawableShapeToolExecutor<T> : SimpleShapeToolExecutor w
     protected double StrokeWidth => toolbar.ToolSize;
 
     protected Paintable FillPaintable =>
-        toolbar.Fill ? toolbar.FillBrush.ToPaintable() : Colors.Transparent;
+        toolbar.Fill ? toolbar.FillBrush?.ToPaintable() : Colors.Transparent;
 
     protected Paintable StrokePaintable => toolbar.StrokeBrush.ToPaintable();
     protected bool drawOnMask;
@@ -96,7 +96,7 @@ internal abstract class DrawableShapeToolExecutor<T> : SimpleShapeToolExecutor w
             toolbar.StrokeBrush = shapeData.Stroke.ToBrush();
             toolbar.FillBrush = shapeData.FillPaintable.ToBrush();
             toolbar.ToolSize = shapeData.StrokeWidth;
-            toolbar.Fill = shapeData.FillPaintable is ColorPaintable cp && cp.Color != Colors.Transparent;
+            toolbar.Fill = shapeData.FillPaintable.AnythingVisible;
             initialCorners = shapeData.TransformationCorners;
 
             ShapeCorners corners = vectorLayerHandler.TransformationCorners;

+ 1 - 1
src/colorpicker

@@ -1 +1 @@
-Subproject commit 939bc439f1fa48a38b6f7d0c9afc96654566529a
+Subproject commit 93d8bce4b1ff555e8c6bce99b3a3004cf1a5de69