{"id":30337,"date":"2020-10-02T15:54:25","date_gmt":"2020-10-02T19:54:25","guid":{"rendered":"https:\/\/mjtsai.com\/blog\/?p=30337"},"modified":"2020-11-30T15:30:51","modified_gmt":"2020-11-30T20:30:51","slug":"macos-big-sur-changes-for-developers","status":"publish","type":"post","link":"https:\/\/mjtsai.com\/blog\/2020\/10\/02\/macos-big-sur-changes-for-developers\/","title":{"rendered":"macOS Big Sur Changes for Developers"},"content":{"rendered":"<p><a href=\"https:\/\/wiki.freepascal.org\/macOS_Big_Sur_changes_for_developers#Table_Views\">Free Pascal<\/a> (via <a href=\"https:\/\/twitter.com\/frankreiff\/status\/1311937733011611649\">Frank Reiff<\/a>):<\/p>\n<blockquote cite=\"https:\/\/wiki.freepascal.org\/macOS_Big_Sur_changes_for_developers#Table_Views\">\n<p>macOS 11 Big Sur introduces many user interface changes that update the appearance of applications and make them more iOS-like. It also adds support for familiar iOS features &mdash; such as SF Symbols and text styles.<\/p>\n<p>[&#8230;]<\/p>\n<p>By default, toolbars are taller, window titles can display inline with controls, and toolbar items no longer include a bezel.<\/p>\n<\/blockquote>\n<p>I&rsquo;ve found that in order to get the new title bar and the preferences toolbar style, you have to build using Xcode 12. It&rsquo;s not enough to set <code>NSWindow.toolbarStyle<\/code>.<\/p>\n<p>Even when using the new SDK, setting <code>NSControlSizeLarge<\/code> on the view doesn&rsquo;t give you the new large icon style. To get that, you need to use <code>NSToolbarItem.bordered<\/code>, which requires macOS 10.15, instead of creating the view yourself. So that means separate toolbar implementations if you want to support macOS 10.14 and earlier. Because I&rsquo;m no longer creating the view myself, I had to switch from <code>NSSegmentedControl<\/code> to <code>NSToolbarItemGroup<\/code>, but unfortunately <code>NSMenuToolbarItem<\/code> doesn&rsquo;t work when inside of a group.<\/p>\n<p>My main Mac is still on macOS 10.14, so I&rsquo;m using <code>#if __MAC_OS_X_VERSION_MAX_ALLOWED &lt; <a href=\"https:\/\/mjtsai.com\/blog\/2020\/07\/21\/big-sur-is-both-10-16-and-11-0\/\">101600<\/a><\/code> to make the same code compile with both Xcode 11 and Xcode 12.<\/p>\n\n<p>Previously:<\/p>\n<ul>\n<li><a href=\"https:\/\/mjtsai.com\/blog\/2020\/06\/23\/macos-11-0-big-sur-announced\/\">macOS 11.0 Big Sur Announced<\/a><\/li>\n<\/ul>\n\n<p id=\"macos-big-sur-changes-for-developers-update-2020-11-30\">Update (2020-11-30): <a href=\"https:\/\/lapcatsoftware.com\/articles\/BSAppKit.html\">Jeff Johnson<\/a>:<\/p>\n<blockquote cite=\"https:\/\/lapcatsoftware.com\/articles\/BSAppKit.html\"><p>This blog post describes a few things I found while &ldquo;adapting&rdquo; my AppKit apps for macOS 11 Big Sur.<\/p><\/blockquote>","protected":false},"excerpt":{"rendered":"<p>Free Pascal (via Frank Reiff): macOS 11 Big Sur introduces many user interface changes that update the appearance of applications and make them more iOS-like. It also adds support for familiar iOS features &mdash; such as SF Symbols and text styles. [&#8230;] By default, toolbars are taller, window titles can display inline with controls, and [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"apple_news_api_created_at":"2020-10-02T19:54:28Z","apple_news_api_id":"34a4ecc2-58b8-4200-9b4d-c225aa94171b","apple_news_api_modified_at":"2020-11-30T20:30:55Z","apple_news_api_revision":"AAAAAAAAAAAAAAAAAAAAAQ==","apple_news_api_share_url":"https:\/\/apple.news\/ANKTswli4QgCbTcIlqpQXGw","apple_news_coverimage":0,"apple_news_coverimage_caption":"","apple_news_is_hidden":false,"apple_news_is_paid":false,"apple_news_is_preview":false,"apple_news_is_sponsored":false,"apple_news_maturity_rating":"","apple_news_metadata":"\"\"","apple_news_pullquote":"","apple_news_pullquote_position":"","apple_news_slug":"","apple_news_sections":"\"\"","apple_news_suppress_video_url":false,"apple_news_use_image_component":false,"footnotes":""},"categories":[4],"tags":[69,30,1891,71,226],"class_list":["post-30337","post","type-post","status-publish","format-standard","hentry","category-programming-category","tag-cocoa","tag-mac","tag-macos-11-0","tag-programming","tag-xcode"],"apple_news_notices":[],"_links":{"self":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/30337","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/comments?post=30337"}],"version-history":[{"count":2,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/30337\/revisions"}],"predecessor-version":[{"id":30885,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/30337\/revisions\/30885"}],"wp:attachment":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/media?parent=30337"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/categories?post=30337"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/tags?post=30337"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}