mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 11:38:11 +00:00
GTabWidget: Fill the entire tab widget instead of just the bar.
There's no guarantee that child widgets will paint everything, so let's have GTabWidget fill itself.
This commit is contained in:
parent
1af9b6f102
commit
4f77b4e5bc
1 changed files with 2 additions and 2 deletions
|
@ -6,6 +6,8 @@
|
|||
GTabWidget::GTabWidget(GWidget* parent)
|
||||
: GWidget(parent)
|
||||
{
|
||||
set_fill_with_background_color(true);
|
||||
set_background_color(Color::LightGray);
|
||||
}
|
||||
|
||||
GTabWidget::~GTabWidget()
|
||||
|
@ -81,8 +83,6 @@ void GTabWidget::paint_event(GPaintEvent& event)
|
|||
GPainter painter(*this);
|
||||
painter.add_clip_rect(event.rect());
|
||||
|
||||
painter.fill_rect(bar_rect(), Color::LightGray);
|
||||
|
||||
Rect container_rect { 0, bar_height(), width(), height() - bar_height() };
|
||||
auto padding_rect = container_rect;
|
||||
for (int i = 0; i < container_padding(); ++i) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue