Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to fix black foreground color for selected text item in Eclipse dark theme(s)

With Eclipse 2020-09 as well as 2020-12, the Eclipse dark themes have a problem on my Windows 10 machine: Selected entries in many tables and dialogues, e.g., variables in the debug perspective, are black on dark. Ironically, it also shows in the "Colors and Fonts" selection dialogue:

enter image description here

I first noticed the problem using DevStyle, but on further examination it appears to equally apply to the native Eclipse "Dark Theme" as well as the "Spectrum (1.0.0)" plug-in.

Unfortunately, I cannot seem to find the relevant setting. Changing the theme to something light and back to dark has not helped, neither has setting "Force Colors", nor uninstalling and reinstalling DevStyle. I have also tried removing the workspace .metadata and the projects' .project, .settings and .classpath and setting it up again from scratch (but in vain).

I can invariably reproduce the problem with a fresh installation on a new, empty workspace:

  1. Download the 64 bit Eclipse IDE 2020-09 installer or the 2020-12 one (also tried downloading & unzipping the 2020-12 Java package).
  2. Install with either Java 11 or 14 (tried both) to some new folder; deselected desktop and menu entry creation.
  3. Start with new directory as workspace.
  4. In market place, select DevStyle and install (tried both only the required item, and the required plus CodeTogether bundle), restart, select Dark Theme.
  5. Open preferences, search, e.g., for font, select top item.
  6. Selected items are black on dark, as in the screenshot above.

I have reproduced this on a second Windows 10 machine with no prior workspace or Eclipse installation.

When following the same steps using the Eclipse 2020-06 Java package, I end up with proper white-on-black text items.

The OS on the machine in question is a Windows 10 Pro, up to date, as Windows claims. I have set the theme to a pre-defined one ("Flowers"). I have switched to the theme "Windows", but that did not change the behaviour (at least of an existing installation). I also ...

  • removed the folder .eclipse in my Windows user folder.
  • removed the folder .p2 in my Windows user folder.

In the same/a very similar setup on a Linux machine, I don't see this problem.

like image 979
Hans Avatar asked Nov 07 '22 05:11

Hans


1 Answers

Someone on the DevStyle forums discovered that the issue appears to be related to your Windows 10 version.

https://www.genuitec.com/forums/topic/devstyle-eclipse-2020-06-dark-theme-issue/#post-664506

Windows 10 version 1809 (released late 2018) experiences the issue, while version 2004 (released mid-2020) does not. I'm experiencing the same issue with 1809, and am not able to upgrade since corporate IT controls our Windows updates.

Your options seem to be:

  • Upgrade to a newer version of Windows 10 - 2004 seems to be confirmed to work
  • Continue to use Eclipse 2020-06 (4.16) which does not experience the issue with older versions of Windows 10
  • Live with the hard-to-read text
like image 147
Eric B Avatar answered Nov 14 '22 09:11

Eric B