Posts

Post not yet marked as solved
0 Replies
220 Views
Reassigning a binding (Opt Maj Enter) for a macro I created a conflict. When I went to resolve it I found that the original keybinding was grayed out, and that it was impossible to reassign the key , or delete the entry. It is quite possible an xlm file somewhere with a problem. Any idea on how to remediate it?
Posted Last updated
.
Post not yet marked as solved
8 Replies
3.1k Views
I have installed Big Sur on an external disk, the internal disk is in Catalina. My profile is admin. When I open a session my password works fine, but when I want to modify something in the system preferences it does not accept my password. Just to ascertain that I did not mix up something I erased the disk, and reinstalled Big Sur. No avail. Any help would be most appreciated. MacBook Air 2020 16 GO i7
Posted Last updated
.
Post marked as solved
8 Replies
1.6k Views
Hello,I'm trying the example from the Combine in Practice video, and I'm getting the below compile error.Use of unresolved identifier 'CombineLatest'I have been doing the classical things.- clean the build folder.- verified if there are loose or redundant connexions in the storyboard.- close the projest and restart xcode.- delete the project data below /Library/Developper.Without any success.If I jump to Jump to Definition on CombineLatest in the code I'm taken directly to the definition in the Combine file.Any help or suggestions will be most helpfull.RegardsLars Xcode : 11.4.1 OS : 10.15.5 beta2 Machine : MacMini 201Memory : 32 GOimport UIKitimport Combineclass ViewController: UIViewController { @Published var password: String = "" @IBAction func passwordChanged(_ sender: UITextField) { password = sender.text ?? "" } @Published var passwordAgain: String = "" @IBAction func passwordAgainChanged(_ sender: UITextField) { passwordAgain = sender.text ?? "" } var validatedPassword: AnyPublisher<String?, Never> { return CombineLatest($password, $passwordAgain) { password, passwordAgain in guard password == passwordAgain, password.count > 8 else {return nil } return password } .map { $0 == "password1" ? nil : $0 } .eraseToAnyPublisher() } override func viewDidLoad() { super.viewDidLoad() // Do any additional setup after loading the view. }}
Posted Last updated
.
Post marked as solved
4 Replies
2.2k Views
I have encountered this "bug" ? in compiling with Xcode 11.3.1.The program compiles and runs fine but the code below does not execute, and the image does not load:if let faceCardImage = UIImage(named: "J♥") { faceCardImage.draw(in: bounds.zoom(by: SizeRatio.faceCardImageSizeToBoundsSize)) }However if I change the code, only the string in the call to UIImage to a string without Emoji the image loads nicely if let faceCardImage = UIImage(named: "11J") { faceCardImage.draw(in: bounds.zoom(by: SizeRatio.faceCardImageSizeToBoundsSize)) }Both images J♥ and11Jexist in Assets.xcassets.For further information the code comes from Lecture 6 of the Stanford CS195 2017-2018 course.I have tried different options of typing the string without any success.I had it running ok in 2018, but is going through the course to refresh my memory.Has anyone an idea of why this does not work ? Or has something changed in Swift since?Any light/explanation on this problem will be highly appreciated.Best regardsLars C
Posted Last updated
.
Post marked as solved
3 Replies
792 Views
Hello,I am likely posting in the wrong place, but I didn't manage to find a forum for the beta version of Xcode.I just downloaded Xcode_11_Beta_7.xip, but when I run it I end up with the version 6 of the beta, dated on august 22nd.Any ideas ?
Posted Last updated
.
Post not yet marked as solved
3 Replies
1.8k Views
Hello,I have a project with 6 simple SwiftUI files, each presenting simple views (Text, Image, Slider, DatePicker...).When I create file number 7 (and following) I get an error on the entry to the VStack { (Unable to infer complex closure return type; add explicit type to disambiguate.)I have tried cleaning the build folder. Closing the project, Xcode, and restarting themIf I create a new projet and paste the below in it compiles and executes rightly.Any ideas ?CheersLarsimport SwiftUIstruct Slider : View { @State var celsius: Double = 0 var body: some View { VStack { Slider(value: $celsius, from: -100.00, through: 100.00, by: 1.0) Text("\(celsius) Celsius is \(celsius * 9 / 5 + 32) Fahrenheit") } }}#if DEBUGstruct Slider_Previews : PreviewProvider { static var previews: some View { Slider() }}#endif
Posted Last updated
.