A UITextView category to highlight MarkDown syntax.
- Set background color for code blocks
- Highlight html tags
- Highlight links and image tags
A simple demo has been provided in the code
- Put a
UITextView
on you UI either by InterfaceBuilder or code - Copy and add all files under
MarkNoteView
sub folder into your project - Include the head file in your viewcontroller
#import "UITextView+MarkNote.h"
- When your text changes, call
updateSyntax
method
- (void)textViewDidChange:(UITextView *)textView{
[_textView updateSyntax];
}
- That is it!
Feel free to check the demo app
MarkNoteView is used in my app MarkNote
Twit me @markmarknote https://twitter.com/markmarknote