Border of arrow panels lack contrast when using High Contrast mode

NEW
Unassigned

Status

()

P3
normal
5 years ago
3 months ago

People

(Reporter: Unfocused, Unassigned)

Tracking

(Blocks: 1 bug, {polish})

Trunk
All
Windows
polish
Points:
2
Bug Flags:
firefox-backlog +

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: tpi:+)

Attachments

(2 attachments)

Created attachment 8436819 [details]
Screenshot - panel

The border of our panels lack contrast when using High Contrast mode. It should use the same color as the border of normal menu popups. See screenshots for comparison.
Flags: firefox-backlog+
Created attachment 8436820 [details]
Screenshot - menu
Blocks: 1016556
No longer blocks: 1022562
This is ThreeDShadow (i.e. a native color), isn't it?
Component: Theme → Themes
Product: Firefox → Toolkit
Summary: Border of panels lack contrast when using High Contrast mode → Border of arrow panels lack contrast when using High Contrast mode
Priority: -- → P4
I think we can make the border stronger by just replacing ThreeDShadow with ThreeDDarkShadow here:

toolkit/themes/windows/global/arrow/panelarrow-vertical-themed.svg

and in the --panel-arrowcontent-border variable here:

toolkit/themes/windows/global/popup.css
Mentor: dao+bmo
Points: --- → 2
OS: Windows 8.1 → Windows
Whiteboard: p=2 → [good first bug][lang=css]
Mentor: dao+bmo
Whiteboard: [good first bug][lang=css]
I believe this is a widget bug. In high contrast mode, ThreeDShadow (used by arrow panels) provides less contrast than ThreeDLightShadow, which seems backwards.
Component: Themes → Widget: Win32
Flags: needinfo?(jmathies)
Priority: P4 → --
Product: Toolkit → Core
Hardware: x86_64 → All
Version: 30 Branch → Trunk
(In reply to Dão Gottwald [:dao] from comment #4)
> I believe this is a widget bug. In high contrast mode, ThreeDShadow (used by
> arrow panels) provides less contrast than ThreeDLightShadow, which seems
> backwards.

ThreeDLightShadow returns COLOR_3DLIGHT
ThreeDShadow returns COLOR_3DSHADOW

http://searchfox.org/mozilla-central/rev/767e1e9b118269f957ca1817138472146278a29e/widget/windows/nsLookAndFeel.cpp#241

We can change the above easily if we need to.

Standard win7 themes with glass:
 COLOR_3DLIGHT = light gray
 COLOR_3DSHADOW = dark gray

High contrast, dark: 
 COLOR_3DLIGHT = white
 COLOR_3DSHADOW = dark gray

Maybe we need to chose a different css value here. MSDN describes the two as:

COLOR_3DLIGHT (ThreeDLightShadow) - "Light color for three-dimensional display elements (for edges facing the light source.)"
COLOR_3DSHADOW (ThreeDShadow) - "Shadow color for three-dimensional display elements (for edges facing away from the light source)."
Flags: needinfo?(jmathies) → needinfo?(dao+bmo)
(In reply to Jim Mathies [:jimm] from comment #5)
> Maybe we need to chose a different css value here. MSDN describes the two as:
> 
> COLOR_3DLIGHT (ThreeDLightShadow) - "Light color for three-dimensional
> display elements (for edges facing the light source.)"
> COLOR_3DSHADOW (ThreeDShadow) - "Shadow color for three-dimensional display
> elements (for edges facing away from the light source)."

You're right, we're abusing these colors, so that's why the contrasts are backwards with dark themes. This actually shows in many places using ThreeDShadow and ThreeDLightShadow where we expect ThreeDLightShadow to provide lower contrast and get the opposite effect in high contrast mode.

I don't think there's any other color available for these kind borders. Maybe we could generate something ourselves based on the Window or -moz-dialog colors, or based on ThreeDShadow? If I remember correctly Gtk widget code already generates ThreeDLightShadow and ThreeDDarkShadow based on ThreeDShadow rather than getting them directly from the OS.
Flags: needinfo?(dao+bmo) → needinfo?(jmathies)

Updated

2 years ago
Flags: needinfo?(jmathies)
Keywords: polish
Priority: -- → P2
Whiteboard: tpi:+
Moving to p3 because no activity for at least 1 year(s).
See https://github.com/mozilla/bug-handling/blob/master/policy/triage-bugzilla.md#how-do-you-triage for more information
Priority: P2 → P3
Moving to p3 because no activity for at least 1 year(s).
See https://github.com/mozilla/bug-handling/blob/master/policy/triage-bugzilla.md#how-do-you-triage for more information
You need to log in before you can comment on or make changes to this bug.