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

Alan Snyder javalists at cbfiddle.com
Sun Sep 30 23:43:21 UTC 2018

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 <https://developer.apple.com/documentation/appkit/nsappearance?language=objc> object with this type directly to one of your views. Instead, assign a light appearance to your view, make sure its allowsVibrancy <https://developer.apple.com/documentation/appkit/nsview/1483793-allowsvibrancy?language=objc> property is set to YES <https://developer.apple.com/documentation/objectivec/yes?language=objc>, 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.

[1] https://bugs.openjdk.java.net/browse/JDK-8181910
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/awt-dev/attachments/20180930/58384e47/attachment.html>

More information about the awt-dev mailing list