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.