From 5b89ad27fb56dcbd926ef53bd08313255ba8e449 Mon Sep 17 00:00:00 2001 From: Ashley Wulber Date: Thu, 12 Dec 2024 01:48:38 -0500 Subject: [PATCH] fix: manually scale the damage --- src/utils/iced.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/utils/iced.rs b/src/utils/iced.rs index b5d930a4..90f5bab9 100644 --- a/src/utils/iced.rs +++ b/src/utils/iced.rs @@ -875,7 +875,7 @@ where let background_color = state_ref.program().0.background_color(theme); let bounds = IcedSize::new(size.w as u32, size.h as u32); let viewport = Viewport::with_physical_size(bounds, scale.x); - + let scale_x = scale.x as f32; let current_layers = internal_ref.renderer.layers(); let mut damage: Vec<_> = old_layers .as_ref() @@ -922,8 +922,10 @@ where &overlay, ); } + let damage = damage .into_iter() + .map(|d| d * scale_x) .filter_map(|x| x.snap()) .map(|damage_rect| { Rectangle::from_loc_and_size(