rtfd(from:)
Returns an NSData object that contains an RTFD stream corresponding to the characters and attributes within aRange.
Declaration
func rtfd(from range: NSRange) -> Data?Discussion
Raises an NSRangeException if any part of aRange lies beyond the end of the receiver’s characters.
When writing data to the pasteboard, you can use the NSData object as the first argument to NSPasteboard’s setData(_:forType:) method, with a second argument of NSRTFDPboardType.