ui::AccentRamp¶
Header: winui/ui/themes/Theme.hpp.
The accent color and the three lighter and three darker shades Windows derives from it, read from the system's color settings. Fluent controls fill accent surfaces with one of the shades instead of the accent itself. A filled accent control at rest uses light2 in the dark theme and dark1 in the light theme, so the surface stands out against the page. The defaults are the shades of Windows' default accent, so a default-constructed OsThemeSnapshot resolves to the colors Windows 11 shows with it: light fills with dark1 #005A9E, dark with light2 #76B9ED.
| Field | Type | Default | |
|---|---|---|---|
base |
Color |
Color::from_argb(0xFF0078D4) |
The accent color itself, which the other fields are tints and shades of. |
light1 |
Color |
Color::from_argb(0xFF429CE3) |
The first lighter shade. |
light2 |
Color |
Color::from_argb(0xFF76B9ED) |
The second lighter shade, the dark theme's accent fill. |
light3 |
Color |
Color::from_argb(0xFFA6D8FF) |
The lightest shade. |
dark1 |
Color |
Color::from_argb(0xFF005A9E) |
The first darker shade, the light theme's accent fill. |
dark2 |
Color |
Color::from_argb(0xFF004275) |
The second darker shade. |
dark3 |
Color |
Color::from_argb(0xFF002642) |
The darkest shade. |