<AWT Dev> questions about JDK-8181910 [macos] Support dark title bars on macOS

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

<AWT Dev> questions about JDK-8181910 [macos] Support dark title bars on macOS

Alan Snyder-3
I gather that this change was reverted, but why does the bug report [1] not refect that?

Also, I believe the proposed change is incorrect, above and beyond its build-breaking feature.

(1) It installs the appearances NSAppearanceNameVibrantLight and NSAppearanceNameVibrantDark, which are inappropriate.

From the AppKit documentation:

Don't assign an NSAppearance object with this type directly to one of your views. Instead, assign a light appearance to your view, make sure its allowsVibrancy property is set to YES, and embed the view in a visual effect view. When you do, AppKit updates your view's appearance to this type.

(2) In macOS 10.14, setting an explicit appearance will override the system-provided default. There needs to be a way to prevent AWT from setting the appearance attribute.

(3) Dynamic changes to the client property apparently will not work, because _STYLE_PROP_BITMASK is not extended with the new style bit.