Post

Replies

Boosts

Views

Activity

Reply to IOS Signal strength issue
Apple don't provide a way of getting the signal strength quality. I am amazed at your ingenious workaround, to retrieve it from the StatusBar... ...but I'm not surprised that Apple have now closed that loophole. Your attempt to get "localStatusBar" from "statusBarManager" is failing, so I guess this is no longer available.
Sep ’22
Reply to Minimum requirement to start app development
Not really. You might be able to use a very old version of Xcode... ...but this would be so far behind the current state of the art, that you would struggle to find relevant resources, and would be unable to deploy to recent devices. I would advise using the current version of Xcode (14), and getting a mac (possibly used) which is capable of running that. Xcode 14 requires macOS Monterey or above, so you're looking at: MacBook Pro introduced in 2015 or later MacBook Air introduced in 2015 or later MacBook introduced in 2016 or later Mac mini introduced in 2014 or later iMac introduced in late 2015 or later iMac Pro Mac Studio Mac Pro introduced in 2013 or later
Sep ’22
Reply to The request of the index was outside the bounds of the array
Your technique is very dangerous, because sooner or later, one of your arrays will be a different size, then the app will crash. Why not gather the different data items into a struct... struct MyData { let date: String let interval: String let duration: String let time: String } ...and then use an array of that struct. Also, when you name things, the name should reflect the type of that thing, so: let date: Date let interval: TimeInterval ...then, you can take advantage of all of Xcode's built-in functionality for comparing and operating on those types.
Sep ’22
Reply to How To Make Optional Variables in SwiftUI View
How about something like this... import SwiftUI struct Test: View { let someClass: SomeClass? var body: some View { VStack { Text("Test") if let someClass { Text(someClass.name) } } } } struct Test_Previews: PreviewProvider { static var previews: some View { let someClass = SomeClass() /// set up your preview SomeClass properties here... return Test(someClass: someClass) } } class SomeClass { let name = "Fred" } And of course you can use: Test(someClass: nil)
Sep ’22
Reply to Space under status bar(dynamic island) in iPhone 14 Pros
The iPhone 14 Pro has a larger area at the top, above the Safe Area. There's a nice explanation of it here: https://useyourloaf.com/blog/iphone-14-screen-sizes/ If you look closely at UseYourLoaf's diagram for the iPhone 14 Pro Safe Area... There's a 54-point height at the top, with an additional 5-point height below it. Perhaps this is what you are running into? Would you like to share your demo code, for further comment?
Sep ’22