I have a uitextview. I want to select the content in the uitextview and make it bold,italics,change colour and add the line spacing.I want to save the content . After saving i want to see the changes.Is there any way to do it
Asked
Active
Viewed 636 times
1 Answers
1
You can do something like this,
textView.textColor = [UIColor orangeColor];
UIFontDescriptor * fontD = [textView.font.fontDescriptor fontDescriptorWithSymbolicTraits:UIFontDescriptorTraitBold | UIFontDescriptorTraitItalic ];
textView.font = [UIFont fontWithDescriptor:fontD size:0];
size:0
means 'keep the size as is'
Hope this will help :)

Ketan Parmar
- 27,092
- 9
- 50
- 75