Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve support for Dark Theme #666

Closed
eric-milles opened this issue Aug 6, 2018 · 4 comments
Closed

Improve support for Dark Theme #666

eric-milles opened this issue Aug 6, 2018 · 4 comments
Assignees
Milestone

Comments

@eric-milles
Copy link
Member

Eclipse has a dark theme (see Window > Preferences > General > Appearance > Theme). When it is switched on, the Groovy Editor looks pretty bad; it does not auto-switch colors that are set in *Window > Preferences > Groovy > Editor. Only the colors inherited from Java syntax coloring change.

eric-milles added a commit that referenced this issue Aug 6, 2018
- Use Java syntax colors for annotations, operators, strings and other
- Move Groovy's as, in, def and trait into keywords and types groups
- Add separate color control for keyword assert
- Fix syntax coloring of @interface and void
- Use old strings color for GJDK (aka category) methods; results in
better contrast to Java syntax colors for both light and dark themes
@eric-milles eric-milles self-assigned this Aug 6, 2018
@eric-milles eric-milles added this to the v3.1.0 milestone Aug 6, 2018
eric-milles added a commit that referenced this issue Aug 6, 2018
- Fix copy of bold preference in Groovy Editor preference page
- Add stylesheets for light <--> dark theme transitions
@eric-milles
Copy link
Member Author

eric-milles commented Aug 6, 2018

TODO:

@mauromol
Copy link

mauromol commented Aug 10, 2018

Hi Eric, I gave a try to Photon with Dark Theme and Groovy. The default colours for Groovy editor are not quite adequate. After using "Copy Java Color Preferences" in Window | Preferences | Groovy | Editor things are much better and the feeling seems to be the same as the one given by the Java editor.
The most visible problem is that class names are black (on a dark grey background), but that's not the only problem.
I don't know how Eclipse theme support works, but maybe you may just dynamically inherit colours from the Java editor by default, unless the user overrides them?

Forgot to say I'm using Greclipse 3.0.0.xx-201808011229-e48.

@eric-milles
Copy link
Member Author

@mauromol I added css for the color switching in the most recent commit on this thread. When you have an open editor, the colors may not change over 100%, but after restart you should not need to alter Window > Preferences > Groovy > Editor colors. But in case those colors don't change over, I did fix the copy from Java so that the bold pref is copied as well.

@mauromol
Copy link

Hi Eric, I just updated to 3.1.0.xx-201808130148-e48 and tried to go to Window | Preferences | Groovy | Editor and hit "Restore defaults". Without any restart, keyword and other colours are set to purple (rather than orange), but a restart seems to fix this (otherwise a "Copy Java Color Preferences" is needed, just like you said).

Class and interfaces names are now white instead of black, so they are much more readable, however in JDT editor class names are blue (interfaces are cyan) instead. Probably the third point of your TODO list?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants