1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 07:08:10 +00:00

HackStudio: Fill the selection rubber-band with some nice alpha color

Make use of the new alpha support in Painter::fill_rect() to fill the
rubber band with some see-through color. :^)
This commit is contained in:
Andreas Kling 2019-11-16 19:31:57 +01:00
parent 89c0b158da
commit 5fc62bcf68

View file

@ -53,8 +53,10 @@ void FormWidget::second_paint_event(GPaintEvent& event)
});
}
if (m_rubber_banding)
painter.draw_rect(rubber_band_rect(), Color::MidMagenta);
if (m_rubber_banding) {
painter.fill_rect(rubber_band_rect(), Color(244, 202, 158, 60));
painter.draw_rect(rubber_band_rect(), Color(110, 34, 9));
}
}
void FormWidget::mousedown_event(GMouseEvent& event)