mirror of
https://github.com/SerenityOS/serenity.git
synced 2025-01-23 09:51:57 -05:00
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. :^)
This commit is contained in:
parent
37b21cfd7d
commit
ba6a77f281
1 changed files with 1 additions and 1 deletions
|
@ -1283,7 +1283,7 @@ void Painter::draw_quadratic_bezier_curve(const Point& control_point, const Poin
|
||||||
|
|
||||||
void Painter::add_clip_rect(const Rect& rect)
|
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());
|
state().clip_rect.intersect(m_target->rect());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue