Understand Mac Catalyst
- What is Mac Catalyst
- What you should consider before transforming your app in a Mac Catalyst ready application
- How to run your iPad app on MacOS
- Development environment: Apple Mac running macOS Catalina or higher with Xcode 13 or higher
- SAP BTP SDK for iOS: Version 7.0 or higher
- Step 1
Mac Catalyst was introduced by Apple in 2019 during
WWDC. Mac Catalyst allows you as a developer to transform your iPad app easily into a MacOS application. Mac Catalyst allows you to change your code to enable or disable certain features for MacOS. For example you can change certain UI elements to fit better on the MacOS platform or implement Menu Bar items and more.
Mac Catalyst combined a lot of the common frameworks and make them available to run both on MacOS as well as iOS, e.g. Foundation.
The big difference is that the underlying UI technologies remained separated on MacOS (
AppKit) as well as on iOS (
UIKit). What Mac Catalyst allows you to do is run
UIKitas well as
SwiftUIon MacOS which allows your iPad ready app to run on Mac.
If you’re interested in Mac Catalyst in more detail, please visit Bring Your iPad App to Mac
- Step 2
Before you transform your app into a MacOS ready app through Mac Catalyst, you should consider if your app is actually suitable for a MacOS application:
- You should definitely familiarize yourself with the Human Interface Guidelines for Mac Catalyst.
- Also think about if you’re using features which are not available on Mac Catalyst like
- Think about your Use Case of the iPad app and think about if that app would make sense on Mac.
- If you already have a well maintained MacOS application released you should think twice if it is helpful to replace it with you iOS app.
- Step 3
The great thing when you transform your app with Mac Catalyst is that Apple gives you a lot of things for free! Not only the platform frameworks, databases as well as services but also the following:
- Functional default menu bar
- Window management including
- Window resizing
- Full screen mode
- Split view support
- Dark Mode support
- Mac Scrollbars with full interaction support
- Scroll support while inactive window
- Using a settings bundle will automatically give you a settings menu
- Step 4
Before you do the necessary steps to make our app Mac ready let’s take a look on how the app is going to look like on all three platforms.
You can see that you’re going to change the appearance on MacOS to a split view having a side bar.
NOTE: If you have created the project with the SAP BTP SDK for iOS Assistant and did check for Mac Catalyst support the deployment info should already be set. You only have to set the Signing & Capabilities to your Team and provisioning profile.
In your Xcode project click on the
TutorialApp.xcprojfile located in the project navigator and make sure that Mac is selected in the Deployment Info section.
Click on Signing & Capabilities tab and select your Team, and Signing Certificate. You can also see that the Bundle Identifier changed using a new prefix
maccatalystto identify a Mac Catalyst app.
That is all you have to do.
Run the app now on
MacOSchoosing the My Mac scheme.
What are the two UI technologies you can build iOS as well as macOS apps with? Select the correct answers.