1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 19:27:44 +00:00

LibWeb: Shrink the inner border radii to accommodate the border widths

This fixes the shape of the subreddit logo on new reddit.
This commit is contained in:
MacDue 2022-07-26 20:43:53 +01:00 committed by Linus Groh
parent 890514a057
commit b68f48eb71
5 changed files with 16 additions and 10 deletions

View file

@ -34,7 +34,7 @@ void NestedBrowsingContextPaintable::paint(PaintContext& context, PaintPhase pha
if (phase == PaintPhase::Foreground) {
auto clip_rect = absolute_rect().to_rounded<int>();
ScopedCornerRadiusClip corner_clip { context.painter(), clip_rect, normalized_border_radii_data() };
ScopedCornerRadiusClip corner_clip { context.painter(), clip_rect, normalized_border_radii_data(ShrinkRadiiForBorders::Yes) };
auto* hosted_document = layout_box().dom_node().content_document_without_origin_check();
if (!hosted_document)