318 questions
0
votes
1
answer
28
views
Custom Trait with UITraitBridgedEnvironmentKey not writing back to UITraitCollection
I'm trying to create a custom UI trait and a matching bridged SwiftUI environment key in my SwiftUI App.
I want to override the environment key in a swift view and then have that reflect in the ...
1
vote
1
answer
30
views
.containerBackground availability incorrect?
I've been meaning to try .containerBackground for a while, having seen it introduced with iOS 17, but now that I did I am left confused, because XCode claims it's available only on iOS 18 or newer:
...
-1
votes
1
answer
47
views
SwiftUI Alert/ConfirmationDialog Not Showing on Subsequent Attempts
SwiftUI Alert Not Showing on Subsequent Attempts in iOS App
I'm experiencing an issue with SwiftUI alerts in my fitness timer app. When a user taps the pause button during a workout, I want to show a ...
0
votes
0
answers
51
views
Animating performBatchUpdates in UICollectionView - how to remove the fade style?
I have a typical ...
"user selects one row, all other rows go away, there is now only one row in the data source, the row's new position is (obviously) now the top and only row: row X slides up ...
0
votes
0
answers
15
views
Flutter draggable widget not showing feedback in iPhone 15
I recently noticed an issue on iPhone 15. I have a word game built in Flutter web, in which the user has to drag and drop tiles to match words with synonyms. For this I have used a draggable widget ...
1
vote
0
answers
71
views
SwiftUI Charts: Animating foregroundStyle of a Mark on iOS17
I'm trying to animate a change of data of a bar chart using Swift Charts. While this works fine on iOS18, the animation of the color does not work on iOS17. Since this also seems to be undocumented ...
0
votes
0
answers
144
views
Swift Charts: chartScrollTargetBehavior fails to snap to a day unit
I am working on a scrollable chart that displays days on the horizontal axis. As the user scrolls, I always want them to be able to snap to a specific day. I implemented the following steps described ...
2
votes
1
answer
686
views
Detect when ScrollView has finished scrolling in iOS 17 SwiftUI
Using iOS 17 as minimum target and .scrollTargetBehavior(.paging) modifier.
I need a callback similar to scrollViewDidEndScrollingAnimation.
The goal is to get the callback only after the page changes ...
1
vote
1
answer
69
views
Button continues to autoRepeat after being hidden, need to cancel
I have a stepper button which is in a higher level view that's hidden based on the adjusted value hitting a threshold.
The bug is that hiding the control doesn't cancel the repeat behaviour even ...
1
vote
1
answer
568
views
App crashes on iOS 17 and below on Xcode 16 with dyld`__abort_with_payload
While updating to Xcode 16, observed that the app runs all okay on all iOS 18 devices and sims but crashes for iOS 17 and below sims and devices.
This is the error:
Thread 1: signal SIGABRT dyld`...
0
votes
0
answers
134
views
Object cannot be nil (key: NSFont) at NSMutableAttributedString in UILabel on iOS 17-18
I am encountering a runtime error in my iOS application when trying to set an NSAttributedString to a UILabel. The crash message on Firebase Crashlytics is:
*** -[__NSDictionaryM setObject:forKey:]: ...
0
votes
1
answer
109
views
Sharing Data Between Swift Views?
I am trying to get my head around sharing data with multiple views using @Obervable protocol but having trouble making it work.
I have created a simple app to demonstrate the issue I am having, which ...
1
vote
0
answers
340
views
Xcode 15/16 crashes immediately when trying to use XCUITest UI recorder on iOS 17/18 device
I am trying to use the XCUITest UIrecorder for some UI tests where having the button identifier isn't enough. But soon as I hit record in Xcode UI test it (Xcode) crashes immediately, if the app is ...
0
votes
0
answers
63
views
App crashes when setup UITabBarController only on ipad ios 17
I am trying to setup UITabBarController, it works fine on iphone but crashes on ipad ios 17
the iphone have the save ios version as the ipad
I use xcode version 15.4
This is my tabbar controller
class ...
2
votes
0
answers
108
views
TextField using ViewThatFits does not show keyboard
When ViewThatFits is used with a text field and the HStack should be shown, SwiftUI seems to retain the VStack layout. Additionally, tapping on any text field to present the software keyboard only ...