mirror of
https://github.com/arduino/Arduino.git
synced 2024-12-01 12:24:14 +01:00
93581b03d7
Previously, only the background color was changed to white or light grey. This worked well for the default theme with a black or dark text, but not for a dark theme with white or light text. This commit fixes this by also overriding the text color to be black. Since the colors are set on the JPanel table cell, but the actual text is rendered by the description JTextPane, the `setForeground` method is overridden to forward the foreground color to the description pane. Note that this commit only touches the table cell and description inside, the dropdowns and buttons have neither background nor foreground color set (thus these use both colors from the system theme). It might be more consistent to also override these, but such native UI components are typically tricky to colorize properly, so best let the system handle that normally. An alternative solution would be only use the default colors, which would actually preserve the dark theme colors in these managers as well (rather than forcing black-on-white/grey as now). There are default colors for selected and non-selected table cells that could be used, but these are different from the current colors. Additionally, the current odd/even alternating colors are then also no longer available. |
||
---|---|---|
.. | ||
.settings | ||
lib | ||
src | ||
test | ||
test-lib | ||
testdata/libraries | ||
.classpath | ||
.classpath_macosx | ||
.editorconfig | ||
.project | ||
build.xml |