Post

Replies

Boosts

Views

Activity

Reply to Problems compiling xcframeworks using Carthage with the latest Xcode beta
Investigating further, it appears that Carthage does not specify the -sdk when compiling for macOS. It does for other platforms. Carthage has good documented reasons for this. It looks Xcode 26 beta 4 and earlier assumed the platform was macOS when it was ambiguous, and Xcode 26 beta 5 does not. I described the issue in more detail in a Carthage ticket: https://github.com/Carthage/Carthage/issues/3399 Would a an FB also make sense? John
3d
Reply to Problems compiling xcframeworks using Carthage with the latest Xcode beta
Thank you for the reply. I am still working my way through this, but I have figured out at least one Xcode behavior change that appears to trigger the issue. Take RSParser: https://github.com/Ranchero-Software/RSParser It moved away from Xcode projects entirely, but at this commit it had an Xcode project I could build with Carthage: fcbd9a34ecd8c080c6f26798a4b22ea0c98d8e74 Carthage runs this command to get a list of build settings: xcodebuild -project RSParser.xcodeproj -scheme RSParser -configuration Release archive -showBuildSettings -skipUnavailableActions With Xcode 26 beta 4, the output had: LLVM_TARGET_TRIPLE_OS_VERSION = macos10.13 With Xcode 26 beta 5, the output has: LLVM_TARGET_TRIPLE_OS_VERSION = ios13.0 This appears to be what makes Carthage not build the .xcframework for macOS. John
3d
Reply to Trying to use UIScrollEdgeElementContainerInteraction
Thank you. I did watch that video a few times, but I still do not understand. I have a custom view controller that serves as my navigation controller. I want it to mimic the behavior of the view's title moving up into the title area. Perhaps UIScrollEdgeElementContainerInteraction will not help me with that anyway, I do not know. The video showed that interaction seeming to blur out content of the view behind it, but I have had no success in implementing that. In my code above, adding the interaction to a view that overlays the scroll view (the table view) does nothing. I am hoping someone can tell me why it does nothing, or what I am missing. Alternatively, I would love to see code I can run that uses UIScrollEdgeElementContainerInteraction successfully. Thank you. John
Topic: UI Frameworks SubTopic: UIKit Tags:
1w
Reply to Hang when opening share sheet
After I was still seeing the behavior when just creating an App Delegate, Scene Delegate, and View Controller that did just about nothing else, I deleted all other code in the app. I could then see the problem was gone. I then put a breakpoint in every method with a dispatch_once_t call. That led me to where my code was being called that I did not expect. I hope this is somehow helpful, @SeanMcMains! John
Topic: UI Frameworks SubTopic: UIKit Tags:
Sep ’22
Reply to Hang when opening share sheet
The crash report said the reason was running out of memory. The app's memory usage would climb by roughly 30MB/second until the app crashed. I since figured out the source of the problem. I had an Objective-C extension on UIColor that implemented secondaryLabelColor. I do not know why that had the effect it did on share sheets, but removing that extension method fixed it. Thank you for replying! John
Topic: UI Frameworks SubTopic: UIKit Tags:
Sep ’22
Reply to "Archiving error" when using a custom font
FYI, I got this helpful response to my FB, and it worked for me. I hope it helps you as well: You can’t use CTFontRegisterGraphicsFont() created from a CGDataProvider for widgets. Instead you can use CTFontManagerRegisterFontsForURL() and it is much simpler than the code you attached:         let bundle = Bundle(for: MyFonts.self)         let url = bundle.url(forResource: "miso-light", withExtension: "otf")!         var error: Unmanaged<CFError>?         if !CTFontManagerRegisterFontsForURL(url as CFURL, .process, &error) {             print("unable to register font: \(error!.takeUnretainedValue())")         } else {             print("registered!")         }
Topic: App & System Services SubTopic: General Tags:
Sep ’20
Reply to WidgetKit and shared object instances
I ended up with a static method that reads a JSON file and returns it as a struct. That method caches the previous result in memory, and uses that result again if the JSON file is unchanged. The JSON file is generated by my app. It contains a small subset of the data from my app's sqlite database, primarily because I wanted to avoid 0xdead10cc crashes.
Topic: App & System Services SubTopic: Core OS Tags:
Sep ’20