Skip to content

Commit 4eebb62

Browse files
committed
fix: non integer image position
1 parent df65c97 commit 4eebb62

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/convert/svg.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,7 @@ impl SvgBuilder {
207207
}
208208

209209
let mut placed_coord_x = (self.margin * 2 + n) as f64 - border_size;
210-
placed_coord_x /= 2f64;
210+
placed_coord_x = (placed_coord_x / 2f64).ceil();
211211
let mut placed_coord = (placed_coord_x, placed_coord_x);
212212

213213
if let Some((x, y)) = self.image_position {

0 commit comments

Comments
 (0)