Matching windows system colors: light on dark

2019-08-08 01:05发布

I'm trying to make my app a good Windows citizen, so I use matching system colors (see "When selecting system colors, match but don't mix") as much as possible. However, sometimes light text on a dark background (something like COLOR_APPWORKSPACE/clAppWorkSpace) seems most appropriate, but the system doesn't provide this. Do you have any recommendations regarding this?

2条回答
我欲成王,谁敢阻挡
2楼-- · 2019-08-08 01:28

You could swap two colors. For example, if you can read InfoText colored text on a InfoBackground colored background, you should be able to read InfoBackground colored text on an Info colored background (or apply the concept to Window and WindowText).

Readability might suffer slightly.

Edit:

Sometimes it is okay to use your own colors, as long as they aren't mixed in with system colors (i.e. don't draw your color text on a system color background). If your own color scheme seems appropriate, then use it. Besides, Windows doesn't have a configurable color for every single need.

查看更多
三岁会撩人
3楼-- · 2019-08-08 01:29

My solution for now: I set the background color to COLOR_APPWORKSPACE/clAppWorkSpace because I assume it has the "dark background" semantic I want. To get a contrasting text color I just get the HLS representation of the same color and increase its lightness factor.

查看更多
登录 后发表回答