mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-09-17 14:30:32 +02:00
remove contex.save and restore
This commit is contained in:
@@ -217,20 +217,20 @@ const drawElementOnCanvas = (
|
||||
}
|
||||
case "freedraw": {
|
||||
// Draw directly to canvas
|
||||
context.save();
|
||||
//context.save();
|
||||
context.fillStyle = element.strokeColor;
|
||||
|
||||
const path = getFreeDrawPath2D(element) as Path2D;
|
||||
const fillShape = getShapeForElement(element);
|
||||
|
||||
if (fillShape && path) {
|
||||
if (fillShape) {
|
||||
rc.draw(fillShape);
|
||||
}
|
||||
|
||||
context.fillStyle = element.strokeColor;
|
||||
//context.fill(path);
|
||||
context.fill(path);
|
||||
|
||||
context.restore();
|
||||
//context.restore();
|
||||
break;
|
||||
}
|
||||
case "image": {
|
||||
|
Reference in New Issue
Block a user