Post

Replies

Boosts

Views

Activity

Reply to Debug Failed in Xcode Simulator
I found a way to fix the debugging issue by deleting all Xcode-related folders and reinstalling Xcode and command-line tools. However, I'm not sure what exactly solved it. Here are my steps: Deleted the following folders/files: /Library/Developer/CommandLineTools /Applications/Xcode.app /Library/Preferences/com.apple.dt.Xcode.plist ~/Library/Preferences/com.apple.dt.Xcode.plist ~/Library/Caches/com.apple.dt.Xcode ~/Library/Application Support/Xcode ~/Library/Developer/* # except /Xcode/UserData and /Xcode/Archives Reboot Install Xcode 16.3 from dmg, run it, accept all agreements, etc. Run xcode-select --install to install Command Line Tools for Xcode After all these steps, breakpoints set while running the app in the Simulator no longer freeze the Simulator/debugger.
Apr ’25
Reply to SwiftUI scroll view page indicator color
There's a more delicate way to update UIPageControl appearance if you are using SwiftUI view from UIKit. // SwiftUI with with UIPageControl struct MyView: View { ... } import SwiftUI import UIKit final class MyViewContainerController: UIHostingController<MyView> {     init() {         let view = MyView()         super.init(rootView: view)     }     @available(*, unavailable)     required init?(coder aDecoder: NSCoder) {         fatalError("init(coder:) has not been implemented")     }     override func viewDidLoad() {         super.viewDidLoad()         let containerTypes = [MyViewContainerController.self]         let appearance = UIPageControl.appearance(whenContainedInInstancesOf: containerTypes)         appearance.currentPageIndicatorTintColor = .systemBlue         appearance.pageIndicatorTintColor = .systemIndigo     } }
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Apr ’22