Best way to learn Xcode and Swift

I have used Xojo since it was RealBASIC and before that I used Delphi, and before that I used Clipper (msdos compiler for dBASE).

I have never used Xcode but feel Xojo’s future doesn’t look to good. What’s the best source of learning how to make the jump from Xojo to Xcode. Seems no one publishes books anymore and most of the video stuff I find is for iOS. I only develop for macOS desktop - and do that on a very limited basis now.

At 70 years old you’d think I would just retire but I tried it and was bored out of my mind.

Well… I have been using Swift since it was first release, and after the release of Xojo 2019r1.1 I left the Xojo world … Elsewhere on this forum you will find a bunch of posts I made surrounding Libraries I have created the replicate Xojo like syntax for many things … I also have started some for macOS and AppleTV as well.

While there is a learning curve (I don’t feel its any worse than Xojo’s was)… but there is a major aspect of Swift that I ignore (on purpose) and that is AutoLayout and Interface builder. I have found they are not necessary, and I build EVERYTHING in code. I even managed a simple class that allows all the LOCK functions in the Xojo IDE without the need for AL.

So anything I can to to help you get started… let me know… I’m 65, retired and bored out of my mind as well

(Right now I’m working on a single Xcode project that compiles for macOS, iPhone, iPad and AppleTV) so while not Xplat as Xojo claims, it covers all the Apple Device families

I’m with you, @plunkettphoto.
I’ve done a good deal of very useful stuff with Xojo – and have generally been happy with its performance, functionality and ease of use.

I’m also somewhat (perhaps overly so?) concerned about its future.

I don’t need cross platform support so that makes Swift / Xcode look interesting. I’m not (currently) interested in iOS dev either and I’ve found a striking lack of online help learning and navigating the MacOS / Swift dev space. (Swift really isn’t the problem for me – it’s more wrapping my head around the paradigms and frameworks.)

All of that having been said, I’ve been porting some of my Xojo projects over to Swift and am making a good deal of progress… learning a LOT along the way.

I’ve found that sllapping together a project in Xojo is pretty quick and easy, however I really appreciate how rich and developed the Swift language and various MacOS frameworks are. I feel as though I can accomplish more with fewer lines of code via Swift/Xcode.

The only recent book that I know specifically covers macOS programming in Swift is ‘Hacking with macOS” by Drew Hudson. It comes in two formats: one for AppKit and another for SwiftUI. Just be aware that a few things might have changed in the upcoming macOS and Swift releases (in most cases, it’s become easier due to new Swift language or SwiftUI features).

Now that the roofers have finished pounding on our roof and the roof across the street, my head’s returning to its default migraine state, so maybe I can start thinking again about writing Swift tutorials for IfNotNil.

By the way, I suggest learning both SwiftUI and at least some AppKit (at minimal, understand how it’s organized, what the main frameworks do, and its main design patterns), but don’t hesitate to use SwiftUI for app releases now. SwiftUI really matured a lot (see the WWDC SwiftUI additions), enough so that many apps can now be coded in SwiftUI and Swift alone — and SwiftUI coding is much easier than AppKit coding (shallower learning curve, less to remember). So for many apps, you might not even need to touch AppKit. The big caveat, of course, is the edge cases when SwiftUI can’t yet do something and AppKit must be accessed directly instead, requiring more knowledge of AppKit in these cases.

Right now, I’m recreating one of my old RB programs (that’s how old it is) totally in SwiftUI and Swift. I’m going to use this opportunity to get my hands dirty with the latest tools and frameworks, and learn best practices for Swift and SwiftUI.

A series based on your learnings might be useful if not educational

Thanks for helpful suggestions. The appkit swiftui issue is part of what I don’t yet completely understand. I’ll checkout the “Hacking…” book.

All this is a long way from COBOL and CICS - not to mention PL/1 and that God Awful thing called RPG that I had to deal with for a year or so.