diff options
author | Andreas Kling <kling@serenityos.org> | 2020-06-06 19:33:18 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2020-06-06 19:36:40 +0200 |
commit | ba6a77f281c243552ced98352dc25f3089e39ea0 (patch) | |
tree | a946180743744572a446a55536189c1862f8897b | |
parent | 37b21cfd7dff8e0d9fa2f65bcf6efab78b6f9c51 (diff) | |
download | serenity-ba6a77f281c243552ced98352dc25f3089e39ea0.zip |
LibGfx: Make Painter::add_clip_rect() use logical coordinates
It was really confusing that add_clip_rect() didn't apply transforms
to the new clip rect, but instead interpreted it as an absolute rect.
This makes web pages with <iframe> render correctly when scrolled.
Something might break from this, but we'll find it soon enough. :^)
-rw-r--r-- | Libraries/LibGfx/Painter.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Libraries/LibGfx/Painter.cpp b/Libraries/LibGfx/Painter.cpp index 543458046a..5c2a67a79c 100644 --- a/Libraries/LibGfx/Painter.cpp +++ b/Libraries/LibGfx/Painter.cpp @@ -1283,7 +1283,7 @@ void Painter::draw_quadratic_bezier_curve(const Point& control_point, const Poin void Painter::add_clip_rect(const Rect& rect) { - state().clip_rect.intersect(rect.translated(m_clip_origin.location())); + state().clip_rect.intersect(rect.translated(translation())); state().clip_rect.intersect(m_target->rect()); } |