From 58c4e266e9ca347e1420abfe997f2b6e2799bb1a Mon Sep 17 00:00:00 2001 From: implicitfield <114500360+implicitfield@users.noreply.github.com> Date: Fri, 16 Jun 2023 17:13:26 +0400 Subject: [PATCH] LibWeb: Prevent double promotion in paint_background --- Userland/Libraries/LibWeb/Painting/BackgroundPainting.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Userland/Libraries/LibWeb/Painting/BackgroundPainting.cpp b/Userland/Libraries/LibWeb/Painting/BackgroundPainting.cpp index b6a302403a2..4c426a628d6 100644 --- a/Userland/Libraries/LibWeb/Painting/BackgroundPainting.cpp +++ b/Userland/Libraries/LibWeb/Painting/BackgroundPainting.cpp @@ -252,7 +252,7 @@ void paint_background(PaintContext& context, Layout::NodeWithStyleAndBoxModelMet x_step = image_rect.width(); repeat_x = false; } else { - auto space = fmod(background_positioning_area.width().to_float(), image_rect.width().to_float()); + auto space = fmod(background_positioning_area.width().to_double(), image_rect.width().to_double()); x_step = image_rect.width() + (space / static_cast(whole_images - 1)); repeat_x = true; }