Terminal: Clip to the paint event rect

We should try to avoid painting any more than what we're asked to.
This commit is contained in:
Andreas Kling 2019-08-13 13:45:58 +02:00
parent 178788f19a
commit ce6463ba76
Notes: sideshowbarker 2024-07-19 12:42:16 +09:00

View file

@ -175,6 +175,8 @@ void TerminalWidget::paint_event(GPaintEvent& event)
GPainter painter(*this);
painter.add_clip_rect(event.rect());
if (m_visual_beep_timer.is_active())
painter.fill_rect(frame_inner_rect(), Color::Red);
else