Images: declare a graphic's clipping path beside its transform

This commit is contained in:
aiongg
2026-10-12 05:32:11 +00:00
parent 8125f2490b
commit e111bb74f7
17 changed files with 25 additions and 25 deletions
+2 -2
View File
@@ -264,10 +264,10 @@ fn flatten(d: &designcraft_doc::Document, cache: &designcraft_compose::Cache, pp
size: (w as f64, h as f64),
xf: designcraft_geom::Affine::translate((r.x0, r.y0))
* designcraft_geom::Affine::scale_non_uniform(r.width() / w as f64, r.height() / h as f64),
clip: None,
auto_fit: Default::default(),
fit_align: 4,
crop: [0.0; 4],
clip: None,
});
it.stroke.weight = 0.0;
it
@@ -430,10 +430,10 @@ fn rasterize_where(
asset: aid,
size: (w as f64, h as f64),
xf: designcraft_geom::Affine::translate((reach.x0, reach.y0)) * designcraft_geom::Affine::scale(1.0 / k),
clip: None,
auto_fit: Default::default(),
fit_align: 4,
crop: [0.0; 4],
clip: None,
});
img_item.stroke.weight = 0.0;
img_item.alt_text = it.alt_text.clone();