mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-11-29 09:52:03 +00:00
Aristo3: Bind toolbar item label colors to appearance-aware theme values
Aristo3 previously left normal toolbar item labels unset—falling back to the class default labelColor—and assigned disabledControlTextColor to disabled labels. Because Aristo3 defines no dark variants for either system color, labels remained black in dark windows. Toolbar item labels now use the theme's activeTextColor and inactiveTextColor, both of which provide light and dark variants. In light mode, the disabled label color shifts from 24.7% to 30% black.
This commit is contained in:
1 parent
45286c9cc4
commit
57287c9354
1 file changed
+9
-1
@@ -9478,7 +9478,15 @@ function A3MaskIcon(aMaskImage, aColor)
|
||||
[@"small-size-height", 46.0],
|
||||
[@"image-item-separator-color", toolbarSeparatorColor],
|
||||
[@"image-item-separator-size", CGRectMake(0.0, 0.0, 2.0, 32.0)],
|
||||
[@"label-color", [CPColor disabledControlTextColor], CPThemeStateDisabled],
|
||||
|
||||
/*
|
||||
The labels were black in a dark window. Aristo3 gave no normal label colour, so the
|
||||
class default labelColor applied, and the disabled colour was the System colour
|
||||
disabledControlTextColor. Aristo3 gives neither System colour a dark value. The labels
|
||||
now take the theme's text colours, which have a light and a dark value.
|
||||
*/
|
||||
[@"label-color", A3CPColorActiveText],
|
||||
[@"label-color", A3CPColorInactiveText, CPThemeStateDisabled],
|
||||
[@"label-color", [CPColor whiteColor], CPThemeStateHUD],
|
||||
[@"label-color", [CPColor colorWithWhite:1.0 alpha:0.5], [CPThemeStateHUD, CPThemeStateDisabled]]
|
||||
];
|
||||
|
||||
Reference in new issue
Block a user