Skip to content

Wrong coloring during debugging for Spring components in the dark theme #357

Closed

Description

@vogella

While initially the colors are correct in the Java editor for Spring components, at some point they switch to yellow. See screenshot.

image

Any idea where this coloring is coming from? I don't think we do this in standard Eclipse but I'm not sure.

Activity

  1. vogella commented on Aug 29, 2019

    @vogella
    Author

    Ah, just learned that this coloring is coming from the language server to show that additional information is available. If that color is defined as a preference you could style it better in the dark theme. Let me know if you want to do this, I can then search for an example how to style preferences via CSS.

  2. changed the title [-]Sometimes coloring wrong for Spring components in the dark theme[/-] [+]Wrong coloring during debugging for Spring components in the dark theme[/+] on Aug 29, 2019
  3. martinlippert commented on Aug 29, 2019

    @martinlippert
    Member

    Absolutely, any pointers and hints would be highly appreciated

  4. added this to the 4.4.0.RELEASE milestone on Aug 29, 2019
  5. vogella commented on Aug 29, 2019

    @vogella
    Author

    OK, I assume you have a preference for this color already. In this case you can contribute styling to the dark theme for this color via an extension.

    Not sure, if you have already a css for the dark theme? If not, create one file ("css/e4-dark_sts4_prefstyle.css") and point via an extension to it:

     <extension
            point="org.eclipse.e4.ui.css.swt.theme">
         <stylesheet uri="css/sts4.css" />
         <stylesheet
               uri="css/e4-dark_sts4_prefstyle.css">
            <themeid
                  refid="org.eclipse.e4.ui.css.theme.e4_dark">
            </themeid>
         </stylesheet>
      </extension>
    

    Within this file you can style your preferences.

    Example (from egit)

    /* ############################## EGIT preferences ############################## */

    /* See bug 466075 about the pseudo-selector ":org-eclipse-egit-ui" */
    IEclipsePreferences#org-eclipse-ui-workbench:org-eclipse-egit-ui {
    		preferences:
    			'org.eclipse.egit.ui.DiffAddBackgroundColor=11,121,90'
    			'org.eclipse.egit.ui.DiffAddForegroundColor=216,254,245'
    			'org.eclipse.egit.ui.DiffHeadlineBackgroundColor=71,71,71'
    			'org.eclipse.egit.ui.DiffHeadlineForegroundColor=242,242,242'
    			'org.eclipse.egit.ui.DiffHunkBackgroundColor=53,97,113'
    			'org.eclipse.egit.ui.DiffHunkForegroundColor=233,242,254'
    			'org.eclipse.egit.ui.DiffRemoveBackgroundColor=117,2,36'
    			'org.eclipse.egit.ui.DiffRemoveForegroundColor=255,232,237'
    			'org.eclipse.egit.ui.IgnoredResourceBackgroundColor=42,42,42'
    			'org.eclipse.egit.ui.IgnoredResourceForegroundColor=120,120,120'
    			'org.eclipse.egit.ui.UncommittedChangeBackgroundColor=42,42,42'
    			'org.eclipse.egit.ui.UncommittedChangeForegroundColor=114,157,186'
    }
    

    The :org-eclipse-egit-ui should be replaced with your plugin ID and is important as you otherwise override styling from other plugins.

  6. vogella commented on Aug 30, 2019

    @vogella
    Author

    @martinlippert do you have a preference for this color already? If yes, please let me know the key for it. I could use a preference initializer to set it to something readable for me until this bug is fixed.

  7. vogella commented on Aug 30, 2019

    @vogella
    Author

    Also the Dashboard could use CSS configured colors with the same approach as described above.

    image

  8. BoykoAlex commented on Sep 5, 2019

    @BoykoAlex
    Contributor

    @martinlippert do you have a preference for this color already? If yes, please let me know the key for it. I could use a preference initializer to set it to something readable for me until this bug is fixed.

    The plugin id: org.springframework.tooling.ls.eclipse.commons
    Preference key: 'STS4BootMarkerIndicationColor'

  9. spring-projects-issues commented on Sep 6, 2019

    @spring-projects-issues

    (comment in Pivotal Tracker added by Alex Boyko:)

    I have updated some colors to use theme in Boot Dash. Also updated green color for boot highlights to come from the Theme. However, I have updated it for the hacky version of marker that is used together with CodeLenses (to work around the bug with CodeLens and marker painting). If CodeLens is off then the marker looks come from org.eclipse.ui.editors.markerAnnotationSpecification ext point. There doesn't seem to be any theme support for this extension, but it is the culprit for the yellow color seen on the screenshot as looks like Eclipse is trying to invert this color automatically based on the background (didn't figure out where yet)
    We do not need the second hacky version of the marker - it's going away. The marker from org.eclipse.ui.editors.markerAnnotationSpecification stays, I might introduce the second marker for the dark theme if i don't find any support for themes

  10. spring-projects-issues commented on Sep 10, 2019

    @spring-projects-issues

    (comment in Pivotal Tracker added by Martin Lippert:)

    one minor thing that I noticed: the background of the filter box in the boot dashboard is a bit too light (in the dark mode), would be better if the background would be darker.

  11. spring-projects-issues commented on Sep 10, 2019

    @spring-projects-issues

    (comment in Pivotal Tracker added by Alex Boyko:)

    I raised https://bugs.eclipse.org/bugs/show_bug.cgi?id=550939 All Text with SWT.SEARCH style look like that :-(

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions