NSTextAttachment 禁止拖动

if (@available(iOS 11.0, *)) { 
     _textView.textDragInteraction.enabled = NO;
    }

另外在YYLable上面展示NSTextAttachmentNSAttributedString,需要将NSAttributedString转成YYTextAttachment

你可能感兴趣的:(NSTextAttachment 禁止拖动)