Post

Replies

Boosts

Views

Activity

Attributed Text Missing Tint Color on Image after Creating From CloudKit Bytes
I've created a simple project which uses CloudKit to store an attributed text as Bytes (Data) The attributed text includes an image with an orange tint color. In my simple project, I have two labels, one for the attributed text which I am loading into CloudKit (putLabel) and one for the attributed text created from the CloudKit data record (getLabel). The putLabel shows the orange image correctly, but the getLabel with attributed text downloaded from the iCloud data shows it as a black image. No tint color. Anybody have any ideas on how to get an attributed text with tint color from CloudKit? Here's the archive code \\ Convert into Data data = try? NSKeyedArchiver.archivedData(withRootObject: mainString, requiringSecureCoding: false) and here's the unarchiver code newStr = try? NSKeyedUnarchiver.unarchivedObject(ofClass: NSMutableAttributedString.self, from: data) The code snippets are missing some things, but they work.
0
0
888
Jul ’22
AttributeGraph: cycle detected through attribute - ScrollView The Cause
I have a number of 'AttributeGraph: cycle detected through attribute' console messages. On a whim, I commented out the two ScrollViews which I have in the app and the messages stopped. I set a symbolic breakpoint at 'print_cycle' to break when the attribute graph cycle is detected. Sure enough, the ScrollView has become the first responder. #5 0x0000000184488a1c in ___lldb_unnamed_symbol120650 () #6 0x00000001849efd94 in ___lldb_unnamed_symbol168748 () #7 0x00000001849ed128 in ___lldb_unnamed_symbol168728 () #8 0x00000001849ec26c in ___lldb_unnamed_symbol168655 () #9 0x00000001849ec400 in ___lldb_unnamed_symbol168660 () #10 0x0000000184baa210 in ___lldb_unnamed_symbol185453 () #11 0x0000000184baa260 in ___lldb_unnamed_symbol185454 () #12 0x00000001a277ed60 in -[UIResponder _setFirstResponder:] () #13 0x00000001a2b29d38 in -[UIView _setFirstResponder:] () #14 0x00000001a277ed50 in -[UIResponder _setFirstResponder:] () #15 0x00000001a2b29d38 in -[UIView _setFirstResponder:] () #16 0x00000001a2ad55ac in -[UIScrollView _becomeFirstResponder] () I can't remove the ScrollViews, so I wonder if there is anything I can do about this.
0
1
1.2k
Jul ’22
SwiftUI MagnifyGesture Suggestion
I am testing out the new MagnifyGesture SwiftUI feature. My suggestion is to bring the view being magnified to the top of all views in the hierarchy while it is being magnified. I've submitted the suggestion in Feedback Assistant. Any comments on this suggestion?
0
0
399
Jul ’23
UICalendarView on Mac Catalyst - Command Key for Multiple Date Selection
A good while back, I created a Mac Catalyst version of an app. The app uses UICalendarView for both iOS and Mac. I have multiple date selection enabled. In the past, I thought I could select multiple dates on the Mac without needing to use the Command key modifier. And now I can't. Is this a change or am I dreaming? How can I go back to being able to select multiple dates without using the command key modifier?
0
0
511
Aug ’23
Xcode 15 RC - CKError: Account temporarily unavailable due to bad or missing auth token
I have two apps which uses the CloudKit public folder so that my users can access data. There's also a private database for them to save data. One is supposed to be able to access the public database without being logged into an iCloud account. And it was working fine. But now, with the simulator, I get the titled error message. It's fine on a device. But, if I log into the simulator with my iCloud account, I can access the public data.
0
0
625
Sep ’23
Text Above List w/ VStack Appears as View's Title
I am curious about the fact that the Text above the VStack is shown as a title to the view. I didn't know one could place Text above a VStack without another VStack. Here's the partial code showing the situation. @State private var results = [Result]() var body: some View { Text("Songs of Al Di Meola on iTunes") .font(.title3) .fontWeight(.bold) List(results, id: \.trackId) { item in VStack(alignment: .leading) { Text(item.trackName) .font(.headline) Text(item.collectionName) } } .task { await loadData() } } See picture for details.
0
0
461
Jul ’24