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

Dark theme: code completion selection does not have enough contrast -> align with other popular dark themes #1688

Closed
thomasritter opened this issue Feb 15, 2024 · 3 comments
Labels
enhancement New feature or request

Comments

@thomasritter
Copy link

thomasritter commented Feb 15, 2024

Yesterday, I had an interesting call with a user of our source based editor. The user uses Eclipse on a large monitor with the Eclipse dark theme. He showed me that the contrast of the code completion is not high enough for him. Therefore, he always:

a) Opens the code completion
b) Uses tab to highlight the selection. With the highlight the contrast is much better

Here the comparison between:

Selected via tab:
image

Without tab selection:
image

Now, imagine the first selection on a large monitor with a high resolution. The contrast is simply not enough.

Here some examples how other IDEs render the selection without the need to press tab.

Intellij:
Screenshot 2024-02-15 at 09 02 53

VS Code:
Screenshot 2024-02-15 at 09 02 41

Both use a light blue which provides more contrast.

I would propose that the dark theme in Eclipse gets adjusted, too. Having to use tab feels like a hack/workaround. What do you think? @BeckerWdf

@thomasritter thomasritter added the enhancement New feature or request label Feb 15, 2024
@thomasritter thomasritter changed the title Light theme: code completion selection does not have enough contrast -> align with other popular dark themes Dark theme: code completion selection does not have enough contrast -> align with other popular dark themes Feb 15, 2024
@HeikoKlare
Copy link
Contributor

HeikoKlare commented Feb 26, 2024

I agree that having better highlighting would be great. Note that on Windows the issue is even worse, as highlighting in dark theme is always hardly visible: eclipse-platform/eclipse.platform.swt#811

Also note that the GTK implementation already does what you expect. Highlighting of the selected element is always done in a well visible way (no matter whether using tab to have focus or not):
image

I would really appreciate an improvement here (in particualar if it also applies to Windows), I am only a little concerned that this might be something that the native widgets do not allow to style (at least on Windows).

Edit: Just saw that it actually seems to be possible to modify: #1690

@Christopher-Hermann
Copy link
Contributor

With some tweaking of #1690 I successfully activated the new selection highlight coloring feature for code completion. This would resolve the corresponding issue across all platforms.
image

Another fix (at least for MacOS) would be to set the focus to the code completion every time it is opened. This would eliminate the extraneous step of having to manually select the focus with the tab key.

I hope I found some time the next days/weeks to look into this issue and also finish the work on the mentioned PR #1690.

@Christopher-Hermann
Copy link
Contributor

Fixed with the latest commit in the PR. Code completion proposal selection is now always drawn in the selection color.
image

fedejeanne pushed a commit to Christopher-Hermann/eclipse.platform.ui that referenced this issue May 6, 2024
BeckerWdf pushed a commit to Christopher-Hermann/eclipse.platform.ui that referenced this issue May 13, 2024
Christopher-Hermann added a commit to Christopher-Hermann/eclipse.platform.ui that referenced this issue May 22, 2024
Christopher-Hermann added a commit to Christopher-Hermann/eclipse.platform.ui that referenced this issue Jun 5, 2024
Christopher-Hermann added a commit to Christopher-Hermann/eclipse.platform.ui that referenced this issue Jun 6, 2024
Christopher-Hermann added a commit to Christopher-Hermann/eclipse.platform.ui that referenced this issue Jun 6, 2024
…tform/eclipse.platform.swt#811

JFace viewer are using OS selection color to highlight the selected item. On some OS this is not accessible. With this change, the selection color can be changed via color preference in the settings of eclipse. The colors are used to draw selection color for tree and table viewers.
For Windows, the selection color in the dark theme is overwritten to fix the bad default coloring

Fixes eclipse-platform/eclipse.platform.swt#811
Fixes eclipse-platform#1688
Christopher-Hermann added a commit to Christopher-Hermann/eclipse.platform.ui that referenced this issue Jun 6, 2024
…tform/eclipse.platform.swt#811

JFace viewer are using OS selection color to highlight the selected item. On some OS this is not accessible. With this change, the selection color can be changed via color preference in the settings of eclipse. The colors are used to draw selection color for tree and table viewers.
For Windows, the selection color in the dark theme is overwritten to fix the bad default coloring

Fixes eclipse-platform/eclipse.platform.swt#811
Fixes eclipse-platform#1688
fedejeanne pushed a commit to Christopher-Hermann/eclipse.platform.ui that referenced this issue Jun 7, 2024
…tform/eclipse.platform.swt#811

JFace viewer are using OS selection color to highlight the selected item. On some OS this is not accessible. With this change, the selection color can be changed via color preference in the settings of eclipse. The colors are used to draw selection color for tree and table viewers.
For Windows, the selection color in the dark theme is overwritten to fix the bad default coloring

Fixes eclipse-platform/eclipse.platform.swt#811
Fixes eclipse-platform#1688
Christopher-Hermann added a commit to Christopher-Hermann/eclipse.platform.ui that referenced this issue Jun 7, 2024
…tform/eclipse.platform.swt#811

JFace viewer are using OS selection color to highlight the selected item. On some OS this is not accessible. With this change, the selection color can be changed via color preference in the settings of eclipse. The colors are used to draw selection color for tree and table viewers.
For Windows, the selection color in the dark theme is overwritten to fix the bad default coloring

Fixes eclipse-platform/eclipse.platform.swt#811
Fixes eclipse-platform#1688
Christopher-Hermann added a commit to Christopher-Hermann/eclipse.platform.ui that referenced this issue Jun 7, 2024
…tform/eclipse.platform.swt#811

JFace viewer are using OS selection color to highlight the selected item. On some OS this is not accessible. With this change, the selection color can be changed via color preference in the settings of eclipse. The colors are used to draw selection color for tree and table viewers.
For Windows, the selection color in the dark theme is overwritten to fix the bad default coloring

Fixes eclipse-platform/eclipse.platform.swt#811
Fixes eclipse-platform#1688
fedejeanne pushed a commit to Christopher-Hermann/eclipse.platform.ui that referenced this issue Jun 11, 2024
eclipse-platform/eclipse.platform.swt#811

JFace viewer are using OS selection color to highlight the selected
item. On some OS this is not accessible. With this change, the selection
color can be changed via color preference in the settings of eclipse.
The colors are used to draw selection color for tree and table viewers.
For Windows, the selection color in the dark theme is overwritten to fix
the bad default coloring

Fixes eclipse-platform/eclipse.platform.swt#811
Fixes eclipse-platform#1688
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants