Bug 381255 - KMessageWidget::Positive's green background makes links difficult to see
Summary: KMessageWidget::Positive's green background makes links difficult to see
Alias: None
Product: frameworks-kwidgetsaddons
Classification: Frameworks and Libraries
Component: general (show other bugs)
Version: 5.39.0
Platform: Neon Linux
: NOR normal
Target Milestone: ---
Assignee: Christoph Feck
Keywords: accessibility, usability
: 389981 (view as bug list)
Depends on:
Reported: 2017-06-16 00:05 UTC by KDE Neon user
Modified: 2020-05-06 21:04 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:

Blue link is hard to see against a green background (42.87 KB, image/png)
2017-10-23 13:48 UTC, Nate Graham

Note You need to log in before you can comment on or make changes to this bug.
Description KDE Neon user 2017-06-16 00:05:56 UTC
When you upload an image to Imgur with the "Export Image - Share" menu, the success message ("You can find the shared image at: http...") uses a green background color that makes it hard to see the blue link with the default KDE Neon colors.
Comment 1 Nate Graham 2017-10-23 13:04:02 UTC
This is actually a more general issue with the KMessageWidget class. We should fix it there IMHO, so all clients that draw URLs can get the fix.
Comment 2 Nate Graham 2017-10-23 13:48:15 UTC
Created attachment 108524 [details]
Blue link is hard to see against a green background
Comment 3 Christoph Feck 2017-11-08 18:44:14 UTC
Right now it is impossible to customize the colors of links in a QLabel. A possible workaround is to use a QTextBrowser.

Comment 4 Nate Graham 2017-11-08 18:49:18 UTC
Preserving the traditional blue color of an unvisited link is a good idea from a UX standpoint, though, since it's instantly recognizable.

- Stop using KMessageWidget to communicate status in Spectacle
- Move the link outside of the KMessageWidget in Spectacle
- Change KMessageWidget's visual style to allow clearer text presentation. Perhaps the blue/green/red color could only extend to the border, with the center following the theme's standard color scheme?
Comment 5 Nate Graham 2017-11-08 18:53:36 UTC
- Give links a white shadow or outline to make the text stand out from the colored background (I tried this using a CSS stylesheet but it didn't work because text-shadow is a CSS3 property, and Qt's stylesheet support only goes to CSS2, so rendering the shadow would have done be done in C++)
Comment 6 Nate Graham 2017-11-30 14:42:26 UTC
FYI Christoph, we are going to be using the "usability" keyword to track the bugs we're targeting for https://phabricator.kde.org/T6831. I've triaged all existing bugs with that keyword and added some more, including this one. Would you mind if we kept that here?
Comment 7 Christoph Feck 2018-02-07 15:31:02 UTC
*** Bug 389981 has been marked as a duplicate of this bug. ***
Comment 8 Nate Graham 2018-05-08 13:14:37 UTC
Git commit 00bce130d35e9dc398709e690a05f8dde70f52b3 by Nathaniel Graham.
Committed on 08/05/2018 at 13:14.
Pushed by ngraham into branch 'master'.

Make KMessageWidget match Kirigami inlineMessage's style

This patch makes the venerable and wonderful `KMessageWidget` match the slick style of Kirigami's new `inlineMessage` control. As a by-product, it fixes a few usability bugs.

I didn't implement the drop shadow here because I couldn't get it to look right.
Related: bug 385299

Test Plan:
Spectacle, Breeze light, information:

Spectacle, Breeze dark, information:

Spectacle, Breeze light, positive:

Spectacle, Breeze dark, positive:

Dolphin, Breeze light, negative:

Dolphin, Breeze dark, negative:

Dolphin, Breeze light, warning:

Konsole, Breeze light with dark profile theme, warning:

Konsole, Breeze dark with light profile theme, information:

Konsole, Breeze light, information:

Kate, Breeze light, positive:

Kate, Breeze dark, information:

Reviewers: hein, #plasma, #vdg, elvisangelaccio, cfeck

Reviewed By: hein, #plasma, cfeck

Subscribers: broulik, anemeth, abetts, cfeck, mart, fabianr, elvisangelaccio, jnoack, #frameworks

Tags: #frameworks

Differential Revision: https://phabricator.kde.org/D12508

M  +34   -46   src/kmessagewidget.cpp
M  +2    -0    src/kmessagewidget.h