diff --git a/resources/images/print_options_bg_dark.png b/resources/images/print_options_bg_dark.png new file mode 100644 index 000000000..267765cbf Binary files /dev/null and b/resources/images/print_options_bg_dark.png differ diff --git a/resources/images/print_options_bg_disabled_dark.png b/resources/images/print_options_bg_disabled_dark.png new file mode 100644 index 000000000..def651c6a Binary files /dev/null and b/resources/images/print_options_bg_disabled_dark.png differ diff --git a/src/slic3r/GUI/SelectMachine.cpp b/src/slic3r/GUI/SelectMachine.cpp index 0ec6651a2..5dbdeadd0 100644 --- a/src/slic3r/GUI/SelectMachine.cpp +++ b/src/slic3r/GUI/SelectMachine.cpp @@ -4752,9 +4752,9 @@ void PrintOption::enable(bool en) m_printoption_item->enable(en); if (en) { - m_printoption_title->SetForegroundColour("#262E30"); + m_printoption_title->SetForegroundColour(StateColor::darkModeColorFor("#262E30")); } else { - m_printoption_title->SetForegroundColour(wxColour(144, 144, 144)); + m_printoption_title->SetForegroundColour(StateColor::darkModeColorFor(wxColour(144, 144, 144))); } } } @@ -4827,7 +4827,9 @@ PrintOptionItem::PrintOptionItem(wxWindow* parent, std::vector ops, std: Bind(wxEVT_LEFT_DOWN, &PrintOptionItem::on_left_down, this); m_selected_bk = ScalableBitmap(this, "print_options_bg", 22); - m_selected_disbabled_bk = ScalableBitmap(this, "print_options_bg_disabled", 22); + m_selected_bk_dark = ScalableBitmap(this, "print_options_bg_dark", 22); + m_selected_disabled_bk = ScalableBitmap(this, "print_options_bg_disabled", 22); + m_selected_disabled_bk_dark = ScalableBitmap(this, "print_options_bg_disabled_dark", 22); // update the options update_options(ops); @@ -4914,9 +4916,18 @@ void PrintOptionItem::doRender(wxDC& dc) /*selected*/ auto selected_left = selected * PRINT_OPT_WIDTH + FromDIP(4); if (m_enable) { - dc.DrawBitmap(m_selected_bk.bmp(), selected_left, (size.y - m_selected_bk.GetBmpHeight()) / 2); + if (!wxGetApp().dark_mode()) { + dc.DrawBitmap(m_selected_bk.bmp(), selected_left, (size.y - m_selected_bk.GetBmpHeight()) / 2); + } else { + dc.DrawBitmap(m_selected_bk_dark.bmp(), selected_left, (size.y - m_selected_bk_dark.GetBmpHeight()) / 2); + } + } else { - dc.DrawBitmap(m_selected_disbabled_bk.bmp(), selected_left, (size.y - m_selected_disbabled_bk.GetBmpHeight()) / 2); + if (!wxGetApp().dark_mode()) { + dc.DrawBitmap(m_selected_disabled_bk.bmp(), selected_left, (size.y - m_selected_disabled_bk.GetBmpHeight()) / 2); + } else { + dc.DrawBitmap(m_selected_bk_dark.bmp(), selected_left, (size.y - m_selected_bk_dark.GetBmpHeight()) / 2); + } } for (auto it = m_ops.begin(); it != m_ops.end(); ++it) diff --git a/src/slic3r/GUI/SelectMachine.hpp b/src/slic3r/GUI/SelectMachine.hpp index a20037917..962bd2cb4 100644 --- a/src/slic3r/GUI/SelectMachine.hpp +++ b/src/slic3r/GUI/SelectMachine.hpp @@ -177,7 +177,9 @@ private: private: ScalableBitmap m_selected_bk; - ScalableBitmap m_selected_disbabled_bk; + ScalableBitmap m_selected_bk_dark; + ScalableBitmap m_selected_disabled_bk; + ScalableBitmap m_selected_disabled_bk_dark; std::vector m_ops; std::string selected_key; std::string m_param;