Fix blocked-out surfaces on scaled outputs

This commit is contained in:
Ivan Molodetskikh
2024-05-04 20:13:53 +04:00
parent 1394afaae9
commit 641b44e006
+4 -5
View File
@@ -732,18 +732,17 @@ impl<W: LayoutElement> Tile<W> {
// user-provided radius, so our blocked-out rendering should match that
// radius.
if radius != CornerRadius::default() && has_border_shader {
let elem_geo = elem.geometry(Scale::from(1.)).to_logical(1);
return BorderRenderElement::new(
elem_geo.size,
Rectangle::from_loc_and_size((0, 0), elem_geo.size),
geo.size,
Rectangle::from_loc_and_size((0, 0), geo.size),
elem.color(),
elem.color(),
0.,
Rectangle::from_loc_and_size(geo.loc - elem_geo.loc, geo.size),
Rectangle::from_loc_and_size((0, 0), geo.size),
0.,
radius,
)
.with_location(elem_geo.loc)
.with_location(geo.loc)
.into();
}