Apple added CGPath boolean operations in iOS 16, macOS 13, etc. Awesome! Why was I not informed???

https://developer.apple.com/documentation/coregraphics/cgpath/3994964-intersection

Documented in the header file, but not in the docset.

Apple Developer Documentation

@mayoff unfortunately missing on SwiftUI.Path so you have to convert back and forth
@mayoff They really should have made a What’s New in CGPath session video and show off the various methods for a solid 5 minutes. So good!
@mayoff yeah, I have been using these APIs. They still have occasional improvements on CG
@mayoff That fourth one always gets a different name in every programming language and library.
@mayoff and I want a backport of that 🥺
@mayoff @timonus This is exactly why I used to prefer to start with the header diffs and then dig into the docs.
@mayoff already using it in one of my unreleased projects. Works nicely.
@mayoff this is wonderful! I wonder if I can find out who did the implementation…
@mayoff I was *just* looking for this. Cheers!

@mayoff oh man, i totally missed all this stuff. and really could have used it recently. Swift only?

Question for Swift UIKit/AppKit devs:

Is all of Core Graphics ported to Swift now or are some bits still C only?

Is there a doc/webpage/header that shows which bits are in each language?

Or maybe unified docs that show both?

Or maybe headers?

It would be worth it to spend a day grepping headers to avoid missing stuff again.

Apple Developer Documentation

@LeoNatan @mayoff

so it looks like the answer is that there ARE equivalent C functions for the new CG things posted about earlier.

but the docs don’t link the Swift <—> C functions for some reason. the little language control at the top of the documentation shows only Swift on the Swift pages and only Obj-C on the Obj-C pages.
maybe because they’re slightly different in some significant way?

or just a doc bug?

either way i’d bet this has been the source of more confusion than just my own.

@isaiah @mayoff Well, I see Apple hasn’t even bothered adding documentation for the C API on their website, which is typical Apple doc. Not sure about the header file.

I don’t think Apple ever specifies what API they are using underneath their Swift overlays, as that’s implementation detail that is not necessarily important.