1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 15:48:12 +00:00

LibGUI: Use LightGray as the base UI color.

This feels nicely reminiscent of the gap in time between Win3.11 and Win95,
one of my favorite eras in UI look-and-feel.
This commit is contained in:
Andreas Kling 2019-02-04 11:51:42 +01:00
parent 6f787f6877
commit 7fe600f250
4 changed files with 5 additions and 2 deletions

View file

@ -65,6 +65,7 @@ void GCheckBox::paint_event(GPaintEvent&)
2, height() / 2 - s_box_height / 2 - 1, 2, height() / 2 - s_box_height / 2 - 1,
s_box_width, s_box_height s_box_width, s_box_height
}; };
painter.fill_rect(box_rect, Color::White);
painter.draw_rect(box_rect, Color::Black); painter.draw_rect(box_rect, Color::Black);
if (m_being_modified) { if (m_being_modified) {

View file

@ -8,6 +8,7 @@
GTextBox::GTextBox(GWidget* parent) GTextBox::GTextBox(GWidget* parent)
: GWidget(parent) : GWidget(parent)
{ {
set_background_color(Color::White);
} }
GTextBox::~GTextBox() GTextBox::~GTextBox()

View file

@ -10,7 +10,7 @@ GWidget::GWidget(GWidget* parent)
: GObject(parent) : GObject(parent)
{ {
set_font(nullptr); set_font(nullptr);
m_background_color = Color::White; m_background_color = Color::LightGray;
m_foreground_color = Color::Black; m_foreground_color = Color::Black;
} }

View file

@ -33,6 +33,7 @@ private:
ClockWidget::ClockWidget(GWidget* parent) ClockWidget::ClockWidget(GWidget* parent)
: GWidget(parent) : GWidget(parent)
{ {
set_font(Font::default_bold_font());
set_relative_rect({ 0, 0, 100, 40 }); set_relative_rect({ 0, 0, 100, 40 });
start_timer(250); start_timer(250);
} }
@ -46,7 +47,7 @@ void ClockWidget::paint_event(GPaintEvent&)
sprintf(timeBuf, "%02u:%02u:%02u", tm.tm_hour, tm.tm_min, tm.tm_sec); sprintf(timeBuf, "%02u:%02u:%02u", tm.tm_hour, tm.tm_min, tm.tm_sec);
Painter painter(*this); Painter painter(*this);
painter.fill_rect(rect(), Color::White); painter.fill_rect(rect(), Color::LightGray);
painter.draw_text(rect(), timeBuf, Painter::TextAlignment::Center, Color::Black); painter.draw_text(rect(), timeBuf, Painter::TextAlignment::Center, Color::Black);
} }