microscope-cockpit / cockpit

Cockpit is a microscope graphical user interface. It is a flexible and easy to extend platform aimed at life scientists using bespoke microscopes.
https://microscope-cockpit.org
GNU General Public License v3.0
37 stars 27 forks source link

Abort button text colour on Mac #818

Closed iandobbie closed 2 years ago

iandobbie commented 2 years ago

The Abort button has lost its text colour on more modern Macs. Not sure exactly when it happened but I found a fix today. The current code uses (gui/mainwindow.py about line 104)

    abortButton.SetLabelMarkup("<span foreground='red'><big><b>ABORT</b></big></span>")

If you replace this with abortButton.SetOwnForegroundColour(wx.RED)

You get the red foreground text colour. Not sure how other systems behave with this.

carandraug commented 2 years ago

If you replace this with abortButton.SetOwnForegroundColour(wx.RED)

Works for me as well. I have pushed 491f22ebc784 which does a slightly different thing to completely remove the need to SetLabelMarkup. Closing as fixed.