On This Day Mac screen shot
On This Day - Mac OS

Why this app?.

One of the things I really wanted to get into was developing Mac applications for my own use. When I first started playing around with XCode development, I had a hankering for a MacOS application, but found very little on the web that clearly covered even the basics of a Mac application, such as how to change the menus, customise the About popup or create a simple preferences screen.

With so little on the Web, I avoided Mac development and played around the edges of iOS development instead. I did figure some of it out eventually and produced my one and only Mac application; MacWasher which is a thin wrapper around Mailwasher Mobile. I still use it, so I must have done something right.

However, it wasn't a 'proper' Mac application in my eyes. Fast forward a while and we're in to SwiftUI and everything is much simpler... except there still isn't that much in the way of tutorials that gets you started. Then, I cam across a book on the Ray Wenderlich site and everything took a leap forward. This book, while a little pricey, covers everything that I had previously been struggling with, including custom menus, custom about popup, custom preferences screen and all the basics of laying out a Mac application using SwiftUI. And that's just the first project!

This is the resulting application from the first part of the tutorial, together with several tweaks of my own.

Key Learning Points

What did I want to achieve?

This being one of my first Mac specific applications, there were a lot of opportunities to learn new concepts. What I wanted from this included:

  • Supporting light/dark mode.
  • Layout in a SwiftUI application in the 'traditional' Mac style.
  • Customising the menus.
  • Handling preferences.
  • Handling multiple windows.
  • Spicing up the About window.

What it looks like

And the end result is...

And this is what I ended up with once the first version was finally complete. It's a traditional style Mac application that works in the way you would expect a Mac application to work - which is always a good thing to strive for.

Caveat; I'm pretty rubbish at recording these demos, so the video is a bit disjointed in places. Sorry about that - I'll try to do better when I have had some more practice.

Source code

No secrets here

If anyone wants to take a look at the code, it's up on GitHub in my On This Day - Mac repo.

Testimonials
Testimonials

Am I really any good?

Don't take my word for my abilities, take a look at other peoples opinions about me.