public static string GetTextRange(this NSTextView textView, NSRange range) { var data = textView.RtfFromRange(range); NSError error; NSDictionary dictionary; var attributedString = new NSAttributedString(data, new NSDictionary(), out dictionary, out error); return(attributedString.Value); }