Post

Replies

Boosts

Views

Activity

Reply to How to schedule local notifications at slightly different times everyday in Swift?
The problem is that you can test only once a day, that makes debugging harder. Very quick reading so far. Have you checked, each day, the values of let sunriseGoldenHourStart = sunlight.calculate(.dawn, twilight: .custom(-4)) let sunsetGoldenHourStart = sunlight.calculate(.dusk, twilight: .custom(6)) Why repeats true, do you really want it to be repeated once user has read ? In anywise, I would try not to repeats false Take care also, if formattedSunsetGoldenHourStart.minute is less than 30, you'll have an error.
Topic: UI Frameworks SubTopic: UIKit Tags:
Mar ’21
Reply to Users are not able to login after updating ios version to 14+
What exact error do you get ? Crash ? Should check this: Do you have any non-ASCII characters in your App name? There's this new issue appearing in iOS 14 app, where asking permissions on iOS 14 app which has any non-ASCII characters crashes the app. See: https://stackoverflow.com/questions/63938854/react-native-ios-14-only-attempt-to-insert-nil-object-from-objects0-29970 You should also ask directly to React Native.
Topic: App & System Services SubTopic: Core OS Tags:
Mar ’21
Reply to How to detect when a user clears all notifications from Notification Center
Apparently, there is no way to receive a notification when you clear all notifications (as explained in previous link). So, maybe a work around would either to: cyclically in your app to refresh its badge by checking how many notifications remain pending. Find info here: https://stackoverflow.com/questions/49309223/run-a-periodic-task-in-background-independent-from-viewcontrollers set a timer in each VC example here: https ://www.hackingwithswift. com/example-code/system/how-to-make-an-action-repeat-using-timer Frequency of one every 10 seconds would probably be enough (in termes of User experience), which would not drain too much resources.
Topic: App & System Services SubTopic: Core OS Tags:
Mar ’21
Reply to Splitting text into cards
Splitting text into cards Usually, it is better UI to have text in a scrollView than in different cards. the title must appear once on the first card That will be harder for user. You'd better keep a title, adding "Cont'd" at the end. Now if you still want to do this. you can have several cards (VCs) or only one in which you will change the content of textView and title. What you have is to evaluate the size needed for some text. Use func boundingRect(with size: CGSize, options: NSStringDrawingOptions = [], context: NSStringDrawingContext?) - CGRect See here how to use: https://stackoverflow.com/questions/19128797/calculating-uilabel-text-size You will have to iterate on the original text: startPoint = first char endPoint : last char of next word compute the rect it it fits, test with next word for end point if does not fit, keep the previous endPoint: that is where you have to split For next card, start at previous endPoint and repeat the algorithm above.
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Mar ’21
Reply to How popular is Dark Mode?
@nathanmark  My dark mode is not working. Does anyone know any solution? Solution to what precise problem ? If you want some useful answer, you should explain: what is "not working" ? what did you do to implement it ? Did you set all colors to be system colors ? which versions of iOS, Xcode ? Does it occur on simulator and / or device
Topic: UI Frameworks SubTopic: UIKit Tags:
Mar ’21