#19819 new defect (fixed)
[patch] Issues with dark modes — at Version 17
| Reported by: | Klumbumbus | Owned by: | simon04 |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | Plugin flatlaf | Version: | |
| Keywords: | dark mode color | Cc: | DevCharly |
Description (last modified by )
This is a collection of issues with dark mode, especially with FlatLaf Dark, reported before on different places. The reason might be in JOSM core, the FlatLaf plugin or the FlatLaf Laf itself.
- The text in the status bar is nearly unreadable --> see 3rd screenshot in #19027 (https://i.ibb.co/crH9GbP/Snag-27625a08.png)
- Similar issue with info box message about new mails in the bottom left corner screenshot.
- Blue links are hard to read --> ticket:19027#comment:24
- Boolean values with icons in menus are hard to see if checked or unchecked --> attachment:check_boxes_dark_mode.png (Windows LaF for comparison on the right, original reported in #19785)
- The warning message in the upload dialog looks not good (light orange background color) --> attachment:upload_dark_mode.png (original reported as facebook comment)
- General issue with too light background colors
- skyper on #19027 comment 23:
Think all background colors, except blue, of boxes like in relation manager and history viewer could be darker at least two of the three colors. Would prefer a darker red and yellow/orange leaving the green lighter for color-bind users (screenshot).
- skyper on #19027 comment 23:
Change History (27)
by , 5 years ago
| Attachment: | check_boxes_dark_mode.png added |
|---|
by , 5 years ago
| Attachment: | upload_dark_mode.png added |
|---|
comment:1 by , 5 years ago
comment:2 by , 5 years ago
| Keywords: | dark mode added |
|---|
by , 5 years ago
| Attachment: | josm_history_dark_mode.png added |
|---|
screenshot of history viewer in dark mode
comment:4 by , 5 years ago
| Keywords: | color added |
|---|
comment:6 by , 5 years ago
I've attached a patch to fix the text color in the status bar: attachment:JOSM-statusbar-foreground-fix.diff
There are actually two issues:
- there are background and foreground colors for status bar defined in "Preferences > Display settings > Colors", but only background color is used
- when changing those colors in Preferences dialog, the status bar colors are not updated because checking for a wrong key prefix
comment:7 by , 5 years ago
I've attached a patch that fixes the blue links in various dialogs and in help browser.
attachment:JOSM-FlatLaf-blue-links-fix.diff
The solution is to use UIManager.getColor("Component.linkColor") to get a link color from the current look and feel.
If not available, use the default color (blue).
by , 5 years ago
| Attachment: | JOSM-FlatLaf-blue-links-fix.diff added |
|---|
fix blue links (updated to use ColorHelper.color2html())
by , 5 years ago
| Attachment: | JOSM-NamedColor-from-Laf.diff added |
|---|
allow class NamedColorProperty to get a default color from the current look and feel
by , 5 years ago
| Attachment: | OSM-FlatLaf-plugin-NamedColors.diff added |
|---|
FlatLaf plugin: define some named colors for validation, status bar, etc
by , 5 years ago
| Attachment: | upload_dark_mode_fixed.png added |
|---|
comment:8 by , 5 years ago
I've attached two patches that support dark (LaF provided) default colors for named colors.
attachment:JOSM-NamedColor-from-Laf.diff
attachment:OSM-FlatLaf-plugin-NamedColors.diff
JOSM "named colors" use class NamedColorProperty and have hard coded default color for light LaFs.
They can be changed in "Preferences > Display settings > Colors".
There is no way to have different colors for light and dark LaFs in class NamedColorProperty.
So the idea to solve this simply is to first ask the Laf (with UIManager.getColor(key)) for a default color.
If the Laf does not provide on, use the hard coded default color.
This is what attachment:JOSM-NamedColor-from-Laf.diff does.
Second part it to define dark colors in FlatLaf plugin: attachment:OSM-FlatLaf-plugin-NamedColors.diff
It works good, but maybe you core developers have a better idea/solution?
I've added a few colors for validation, status bar and imagery. This fixes the "Upload" dialog, makes the status bar darker and fixes the too bright green in tables in "Preferences > Imagery preferences > Imagery providers" dialog.
The screenshot shows also fixed link colors from patch attachment:JOSM-FlatLaf-blue-links-fix.diff
I'll provide a patch for the double borders on some combo boxes soon...
follow-up: 10 comment:9 by , 5 years ago
| Summary: | Issues with dark modes → [patch] Issues with dark modes |
|---|
Thx for the patches.
comment:10 by , 5 years ago
comment:17 by , 5 years ago
| Description: | modified (diff) |
|---|




Ticket #19785 has been marked as a duplicate of this ticket.