LibGfx: Fix drawing rounded corners when using display scaling
This commit is contained in:
parent
49539abee0
commit
40f7977508
Notes:
sideshowbarker
2024-07-18 11:38:16 +09:00
Author: https://github.com/gunnarbeutner Commit: https://github.com/SerenityOS/serenity/commit/40f7977508b Pull-request: https://github.com/SerenityOS/serenity/pull/8212 Reviewed-by: https://github.com/Lubrsi
1 changed files with 4 additions and 0 deletions
|
@ -352,6 +352,10 @@ void Painter::fill_rounded_corner(const IntRect& a_rect, int radius, Color color
|
|||
if (translated_a_rect.y() < rect.y())
|
||||
clip_offset = rect.y() - translated_a_rect.y();
|
||||
|
||||
radius *= scale();
|
||||
rect *= scale();
|
||||
clip_offset *= scale();
|
||||
|
||||
RGBA32* dst = m_target->scanline(rect.top()) + rect.left();
|
||||
const size_t dst_skip = m_target->pitch() / sizeof(RGBA32);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue