diff options
author | Andreas Kling <awesomekling@gmail.com> | 2019-02-05 11:42:35 +0100 |
---|---|---|
committer | Andreas Kling <awesomekling@gmail.com> | 2019-02-05 11:42:58 +0100 |
commit | 38f589a9cb174bd47789f10255ea249df8e18f15 (patch) | |
tree | c5267c6f6e5ceea1a9f9053ce6a426cb5797a321 /WindowServer/WSWindowManager.cpp | |
parent | b782055b96f30e28b979769f517274fda7a57825 (diff) | |
download | serenity-38f589a9cb174bd47789f10255ea249df8e18f15.zip |
SharedGraphics: Add some useful painting helpers and make use of them.
Diffstat (limited to 'WindowServer/WSWindowManager.cpp')
-rw-r--r-- | WindowServer/WSWindowManager.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/WindowServer/WSWindowManager.cpp b/WindowServer/WSWindowManager.cpp index eb64e487b4..93f8c59a89 100644 --- a/WindowServer/WSWindowManager.cpp +++ b/WindowServer/WSWindowManager.cpp @@ -236,8 +236,9 @@ void WSWindowManager::paint_window_frame(WSWindow& window) if (!s_close_button_bitmap) s_close_button_bitmap = CharacterBitmap::create_from_ascii(s_close_button_bitmap_data, s_close_button_bitmap_width, s_close_button_bitmap_height).leak_ref(); - m_back_painter->fill_rect_with_gradient(close_button_rect, Color::LightGray, Color::White); - m_back_painter->draw_rect(close_button_rect, Color::Black); + m_back_painter->fill_rect_with_gradient(close_button_rect.shrunken(2, 2), Color::LightGray, Color::White); + + m_back_painter->draw_rect(close_button_rect, Color::Black, true); auto x_location = close_button_rect.center(); x_location.move_by(-(s_close_button_bitmap_width / 2), -(s_close_button_bitmap_height / 2)); m_back_painter->draw_bitmap(x_location, *s_close_button_bitmap, Color::Black); |