Snap quad primitives to the pixel grid (once again!)

Let's hope this approach handles common cases better.
This commit is contained in:
Héctor Ramón Jiménez 2025-05-25 21:27:00 +02:00
parent 7c5a4bc465
commit 3aedbd5844
No known key found for this signature in database
GPG key ID: 7CC46565708259A7
3 changed files with 15 additions and 18 deletions

View file

@ -424,7 +424,7 @@ where
.style(&self.class, self.last_status.unwrap_or(Status::Disabled));
let border_radius = bounds.height / BORDER_RADIUS_RATIO;
let space = SPACE_RATIO * bounds.height;
let space = (SPACE_RATIO * bounds.height).round();
let toggler_background_bounds = Rectangle {
x: bounds.x + space,