Bug 99116 - StartCenter’s hardcoded color scheme doesn’t work for high-contrast mode users
Summary: StartCenter’s hardcoded color scheme doesn’t work for high-contrast mode users
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: UI (show other bugs)
Version:
(earliest affected)
5.1.1.3 release
Hardware: x86-64 (AMD64) Windows (All)
: medium minor
Assignee: Not Assigned
URL:
Whiteboard: target:24.8.0 target:24.2.0.2
Keywords: accessibility, difficultyInteresting, easyHack, skillCpp, topicDesign
: 129725 (view as bug list)
Depends on:
Blocks: Start-Center High-Contrast 148282
  Show dependency treegraph
 
Reported: 2016-04-06 10:10 UTC by Martin Lemburg
Modified: 2023-12-25 06:33 UTC (History)
13 users (show)

See Also:
Crash report or crash signature:


Attachments
The LibreOffice UI while having switched on high-contrast-mode/theming (52.74 KB, image/png)
2016-04-06 10:10 UTC, Martin Lemburg
Details
A detail hovering the mouse over a listed item on the left of the LibreOffice UI in high-cotnrast-mode/theming (3.50 KB, image/png)
2016-04-06 10:11 UTC, Martin Lemburg
Details
Screenshot of rendering in high-contrast mode of the start center (LibreOffce 5.4.2.2) (235.14 KB, image/png)
2017-11-02 11:37 UTC, Martin Lemburg
Details
Colors used for "responsive" design in the start center (LibreOffcie 5.4.2.2) in high-contrast-mode (4.06 KB, image/png)
2017-11-02 11:39 UTC, Martin Lemburg
Details
Screenshot of hovering color used in the menu bar and menu items in high-contrast-mode (LibreOffice 5.4.2.2) (5.57 KB, image/png)
2017-11-02 11:44 UTC, Martin Lemburg
Details
current 20201011 master against 7.1.0 - Win10 HC#1 highcontrast mode (82.17 KB, image/png)
2020-10-11 15:06 UTC, V Stuart Foote
Details
current 20201011 master against 7.1.0 - Win10 HC#2 highcontrast mode (75.56 KB, image/png)
2020-10-11 15:07 UTC, V Stuart Foote
Details
Screenshot for discussion on https://gerrit.libreoffice.org/c/core/+/160058 (PS 5) (50.02 KB, image/png)
2023-12-13 09:41 UTC, Michael Weghorn
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Lemburg 2016-04-06 10:10:27 UTC
Created attachment 124125 [details]
The LibreOffice UI while having switched on high-contrast-mode/theming

I started LibreOffice, not one of its applications, on my system with configured high-contrast-mode and chosen high-contrast-#1 theme (yellow text, black background).

The screenshot shows, that the UI ignores high-contrast accessibility in general.
The menu and its dialogs behave acceptable.
Comment 1 Martin Lemburg 2016-04-06 10:11:31 UTC
Created attachment 124126 [details]
A detail hovering the mouse over a listed item on the left of the LibreOffice UI in high-cotnrast-mode/theming
Comment 2 Adolfo Jayme Barrientos 2016-04-12 18:16:21 UTC
→ NEW; updating summary for clarity.
Comment 3 QA Administrators 2017-10-28 17:47:16 UTC Comment hidden (obsolete)
Comment 4 Martin Lemburg 2017-11-02 11:37:30 UTC
Created attachment 137454 [details]
Screenshot of rendering in high-contrast mode of the start center (LibreOffce 5.4.2.2)
Comment 5 Martin Lemburg 2017-11-02 11:39:24 UTC
Created attachment 137455 [details]
Colors used for "responsive" design in the start center (LibreOffcie 5.4.2.2) in high-contrast-mode
Comment 6 Martin Lemburg 2017-11-02 11:42:13 UTC
I tested with LibreOffice version 5.4.2.2 and found still the same rendering issues in high-contrast-mode.

1. Menu bar is black on black and hovering color has insufficient contrast
2. Hovering color over menu items or entries in the left side bar has insufficient contrast
3. The start center uses a light background instead of the system window color (GetSysColor(COLOR_WINDOW)), the default high-contrast-window color.

BTW testing in high-contrast on Windows is not that difficult. The hotkey LeftAlt+LeftShift+PrintScr is normally enabled and toggles the high-contrast-mode with its default or last used high-contrast theme/design.
Comment 7 Martin Lemburg 2017-11-02 11:44:32 UTC
Created attachment 137456 [details]
Screenshot of hovering color used in the menu bar and menu items in high-contrast-mode (LibreOffice 5.4.2.2)
Comment 8 QA Administrators 2018-11-03 03:49:54 UTC Comment hidden (obsolete)
Comment 9 Heiko Tietze 2020-02-26 12:10:31 UTC
*** Bug 129725 has been marked as a duplicate of this bug. ***
Comment 10 Heiko Tietze 2020-02-26 12:12:21 UTC
Code pointer in bug 129725 comment 6; see also bug 129725 comment 15
Comment 11 Heiko Tietze 2020-10-07 07:43:55 UTC
Please check again with a nightly build (should be available tomorrow). Custom colors have been dropped from the start center, see bug 136555.
Comment 12 Thomas Leigh 2020-10-11 13:35:32 UTC
(In reply to Heiko Tietze from comment #11)

Either using a dark theme or not using any theme at all - the start center window is still light-colored-looking (master~2020-10-11_00.12.38_LibreOfficeDev_7.1.0.0.alpha0_Win_x86).
Comment 13 V Stuart Foote 2020-10-11 15:06:05 UTC
Created attachment 166270 [details]
current 20201011 master against 7.1.0 - Win10 HC#1 highcontrast mode

Windows 10 WDM does not adequately pass theme details that LO can apply. And LO does not read the UWP theming overlaid on the WDM.  So Windows 10 (or earlier Win7, Win8.1) does pass in an os/DE flag for 'HighContrast' set triggering the switch to Sifr icons and a read of what limited 'theme' details win32s passes.

IIUC getting this accessibility issue corrected on Windows will require the native code work needed for bug 118320

We used to have the StartCenterBackgroundColor and StartCenterTextColor [1] implemented for consistent SC UI--i.e. "Branding". 

But that was recently stripped out for bug 136555 [2] for "better" os/DE theming support, which of course doesn't work for Windows, and not sure if the macOS builds do better.

=-refs-=
[1] for bug 90452 https://gerrit.libreoffice.org/c/core/+/16622/
[2] for bug 136555 https://gerrit.libreoffice.org/c/core/+/103041
Comment 14 V Stuart Foote 2020-10-11 15:07:51 UTC
Created attachment 166271 [details]
current 20201011 master against 7.1.0 - Win10 HC#2 highcontrast mode
Comment 15 Thomas Leigh 2020-10-11 18:29:24 UTC
(In reply to V Stuart Foote from comment #13)

So are there any chances for LO to gain completely dark-themed start center? So far I’ve been using what now You’ve showed that it has been dropped :( . Although it was still a partial solution.
 
 Vision-wise, I have trouble looking at anything which is light-colored. Therefore it was a big positive surprise when I’ve discovered that I can make documents displayed on a complete dark GUI (including color of a page, which does not influence the color on the print). Those same documents, however, are still displayed within the start center in a form of a final printing version, meaning: white pages. I am therefore wondering if this also would be possible to be included: for the start center to display dark documents, regardless of their colors for print.
 
 But this is a little digression, the main thing remains a complete dark theme for the start center window.
Comment 16 Jan-Marek Glogowski 2020-10-22 12:21:15 UTC
(In reply to V Stuart Foote from comment #13)
> Created attachment 166270 [details]
> current 20201011 master against 7.1.0 - Win10 HC#1 highcontrast mode

This looks the same (AKA broken highcontrast) in the build before the patch was merged. Feel free to revert that patch, if you make the setting optional. Just start Writer on Windows, which looks even more broken in multiple ways, because most backgrounds in the toolbars aren't dark. Also the menu text is green, while it's white in notepad. There is simply much more to fix, but mapping the right colors to LO's theming is generally not rocket science (but probably guesswork, because of the huge amount of theming colors in LO, needed or not).

> We used to have the StartCenterBackgroundColor and StartCenterTextColor [1]
> implemented for consistent SC UI--i.e. "Branding". 
>
> But that was recently stripped out for bug 136555 [2] for "better" os/DE
> theming support, which of course doesn't work for Windows, and not sure if
> the macOS builds do better.

The patch was also a reaction to MacOS based changes, and that author was in the loop. So I guess they are tested on MacOS too.

The start center now uses the colors from the theme for the button area, which uses GetWorkspaceColor, which is supposed to use GetSysColor(COLOR_MENU), but just if officecfg::Office::Common::Accessibility::AutoDetectSystemHC::get(), for whatever reason, instead of always setting it from the theme.

FWIW you can still set the background image for some "branding" of the start center.
Comment 17 Thorsten Wagner 2020-10-24 19:42:07 UTC
(In reply to Jan-Marek Glogowski from comment #16)
> The patch was also a reaction to MacOS based changes, and that author was in
> the loop. So I guess they are tested on MacOS too.

On macOS there is neither a high-contrast mode nor a dark mode. The latter is caused by an incompartibility of current macOS SDKs (not by colors). There are currently no problems with coloring related to Startcenter on macOS.
Comment 18 Timur 2022-09-29 12:33:39 UTC Comment hidden (obsolete)
Comment 19 Timur 2022-09-29 12:58:14 UTC
Start center seems generally working with Win10 high contrast. 
Only wrong I see is Recent Documents, which gets green backround and not system one and Templates, which gets grey backround and not the one from system's Selected text color.
Comment 20 Stéphane Guillou (stragu) 2022-12-30 12:43:10 UTC
High Contrast has greatly improved in LO 7.5. However, here are the issues I can still see:
* use of dark grey in Templates and Recent Documents backgrounds
* use of light grey in Templates and Recent Documents hover/selection highlight
* dismiss cross in Recent Documents lacks contrast (grey/light grey)
* left panel icons don't invert to black on hover (but text does)
* expanded top menu hover colour is correct but the white text does not invert to black (although this is not specific to the Start Center)

Caolán, wondering if you are interested in any of these? Maybe some low-hanging fruit in there, but happy to open more specific follow-up reports.

Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 4b67515418ee4f10071b3f0f2275ba37f32b0ae5
CPU threads: 4; OS: Windows 10.0 Build 19045; UI render: Skia/Raster; VCL: win
Locale: en-GB (en_GB); UI: en-GB
Calc: threaded
Comment 21 Michael Weghorn 2023-12-13 09:41:44 UTC
Created attachment 191404 [details]
Screenshot for discussion on https://gerrit.libreoffice.org/c/core/+/160058 (PS 5)
Comment 22 Commit Notification 2023-12-25 00:03:58 UTC
Yli875 committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/f989ee32b35ee4f0750ae313d35d225d252d64d4

tdf#99116 modify menu highlight text color in high contrast mode on win

It will be available in 24.8.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 23 Commit Notification 2023-12-25 06:33:30 UTC
Yli875 committed a patch related to this issue.
It has been pushed to "libreoffice-24-2":

https://git.libreoffice.org/core/commit/1f7514cf41ea6c3b6deed67ac1cb44364b7722eb

tdf#99116 modify menu highlight text color in high contrast mode on win

It will be available in 24.2.0.2.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.