Ivan Alek Ivan Alek - 1 year ago 173
Markdown Question

UITextView with heavy markdown support

I want to implement UITextView that will be able to present markdown content, including inline Phrase and Sections as shown on this image:
enter image description here

Provided NSAttributedString options are not powerful enough to achieve the border with round corners effect.

This can be done with overriding UIView and then using CoreText for laying down the text and drawing the frame borders, but with this i will lose the ability to select and copy specific parts of the text. Also highlighting urls, emails and phone numbers will be gone with this.

UIWebView is not an option because of performance issues, i will need bunch of these views shown at once.

So, does anybody have idea how to draw rounded borders around words/paragraphs with UITextView?

Answer Source

I found this. It supports inline text border and also block text border, which is exactly what i needed.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download