Don't draw if no paint is active

This commit is contained in:
Laurenz Stampfl 2025-03-27 16:41:47 +01:00
parent 68841294ba
commit 074eedfc51

View File

@ -56,10 +56,13 @@ pub(crate) fn handle_shape(
None
};
// Otherwise, krilla will by default fill with a black paint.
if fill.is_some() || stroke.is_some() {
surface.set_fill(fill);
surface.set_stroke(stroke);
surface.draw_path(&path);
}
}
surface.pop();
surface.reset_location();