From 91c2fd20853b831b7c6e6edeb158ec2d737e590c Mon Sep 17 00:00:00 2001 From: daboe01 Date: Fri, 10 Jun 2022 09:09:36 +0200 Subject: [PATCH] new: focus ring for combobox --- AppKit/Themes/Aristo3/ThemeDescriptors.j | 37 +++++++++++++++++++++++- 1 file changed, 36 insertions(+), 1 deletion(-) diff --git a/AppKit/Themes/Aristo3/ThemeDescriptors.j b/AppKit/Themes/Aristo3/ThemeDescriptors.j index e596d0489..c7bf15143 100644 --- a/AppKit/Themes/Aristo3/ThemeDescriptors.j +++ b/AppKit/Themes/Aristo3/ThemeDescriptors.j @@ -3831,6 +3831,41 @@ var themedButtonValues = nil, @"border-width": @"2px", }], + bezelFocusedCssColor = [CPColor colorWithCSSDictionary:@{ + @"background-color": A3ColorBackgroundWhite, + @"border-color": @"A3ColorBorderBlue", + @"border-style": @"solid", + @"border-width": @"1px", + @"border-radius": @"0px", + @"box-sizing": @"border-box", + @"box-shadow": @"0px 0px 2px 0px rgb(59,127,202)", + @"transition-duration": @"0.35s, 0.35s", + @"transition-property": @"box-shadow, border" + } + beforeDictionary:@{ + @"background-color": @"rgb(225,225,225)", + @"bottom": @"3px", + @"content": @"''", + @"position": @"absolute", + @"right": @"17px", + @"top": @"3px", + @"width": @"1px" + } + afterDictionary:@{ + @"content": @"'⌅'", + @"transform": @"rotate(180deg)", + @"background-color": A3ColorBorderBlue, + @"color": A3ColorBackgroundWhite, + @"border-radius": @"3px", + @"text-align": @"center", + @"right": @"1px", + @"top": @"7px", + @"margin": @"-6px 0px 0px 0px", + @"position": @"absolute", + @"height": @"90%", + @"width": @"15px", + @"border-width": @"2px", + }], notKeyButtonCssColor = [CPColor colorWithCSSDictionary:@{ @"background-color": A3ColorBackgroundWhite, @@ -4097,7 +4132,6 @@ var themedButtonValues = nil, overrides = [ - [@"uses-focus-ring", YES], [@"direct-nib2cib-adjustment", YES], [@"text-color", A3CPColorActiveText], [@"text-color", A3CPColorInactiveText, [CPThemeStateDisabled]], @@ -4105,6 +4139,7 @@ var themedButtonValues = nil, // Bordered, IB style "Push" (CPRoundedBezelStyle) // Regular size + [@"bezel-color", bezelFocusedCssColor, [CPThemeStateBezeled, CPComboBoxStateButtonBordered, CPThemeStateEditing]], [@"bezel-color", buttonCssColor, [CPComboBoxStateButtonBordered, CPThemeStateKeyWindow]], [@"bezel-color", notKeyButtonCssColor, [CPComboBoxStateButtonBordered]], [@"bezel-color", highlightedButtonCssColor, [CPComboBoxStateButtonBordered, CPThemeStateHighlighted]],