summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2024-07-15 20:00:46 +0200
committerCarl Hetherington <cth@carlh.net>2024-07-15 20:00:57 +0200
commite9c728d964e5e9216fde2fc4224fa92cb0070d63 (patch)
treec2310977fffd2753af09deb8d941db21297d0248
parent5c979b94ed19146c1227ba6b4910c23efddaf385 (diff)
Fix nag foreground colour in dark mode (#2848).
-rw-r--r--src/wx/html_dialog.cc7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/wx/html_dialog.cc b/src/wx/html_dialog.cc
index 0543a66d5..44b51bbe0 100644
--- a/src/wx/html_dialog.cc
+++ b/src/wx/html_dialog.cc
@@ -49,13 +49,16 @@ HTMLDialog::HTMLDialog (wxWindow* parent, wxString title, wxString html, bool ok
);
auto h = new wxHtmlWindow (this);
- h->SetPage (html);
- sizer->Add (h, 1, wxEXPAND | wxALL, 6);
if (gui_is_dark()) {
+ h->SetPage(wxString::Format("<body text=\"white\">%s</body>", html));
h->SetHTMLBackgroundColour(wxColour(50, 50, 50));
+ } else {
+ h->SetPage(html);
}
+ sizer->Add (h, 1, wxEXPAND | wxALL, 6);
+
h->Bind (wxEVT_HTML_LINK_CLICKED, boost::bind(&HTMLDialog::link_clicked, this, _1));
SetSizer (sizer);