Posts

Post not yet marked as solved
1 Replies
0 Views
Have you found the answer yet?
Post not yet marked as solved
1 Replies
0 Views
Anyone found any solution yet?
Post not yet marked as solved
4 Replies
0 Views
Using this code to convert Attributed string into Data for making a pasteboard item. extension NSAttributedString {     var convertToData: Data? {         let options: [NSAttributedString.DocumentAttributeKey: Any] = [             .documentType: NSAttributedString.DocumentType.rtfd,             .characterEncoding: String.Encoding.utf8 ]         let range = NSRange(location: 0, length: length)         return try? data(from: range, documentAttributes: options)     }
Post not yet marked as solved
4 Replies
0 Views
In the MacCatalyst, Whenever the user copy something with ctrl + c key commands, data is sent to pasteboard by its own method func copy() method. Even overriding copy() method isn't helping.