mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-30 20:59:16 +00:00
SharedGraphics: Make Painter clipping work with translated clip origin.
This commit is contained in:
parent
8eefdbdce8
commit
fd428d6ed3
Notes:
sideshowbarker
2024-07-19 15:29:12 +09:00
Author: https://github.com/awesomekling
Commit: fd428d6ed3
6 changed files with 20 additions and 9 deletions
|
@ -181,9 +181,10 @@ Rect GScrollBar::scrubber_rect() const
|
|||
return { (int)x_or_y, 0, button_size(), button_size() };
|
||||
}
|
||||
|
||||
void GScrollBar::paint_event(GPaintEvent&)
|
||||
void GScrollBar::paint_event(GPaintEvent& event)
|
||||
{
|
||||
Painter painter(*this);
|
||||
painter.set_clip_rect(event.rect());
|
||||
|
||||
painter.fill_rect(rect(), Color(164, 164, 164));
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue