I\'m trying to parse my own HTML string into an NSAttributedString for rendering in a UITextView.
So, for when the string appears as such:
Here is my answer after looking through different sources:
UIFontDescriptor *fontDescriptor = [UIFontDescriptor preferredFontDescriptorWithTextStyle:UIFontTextStyleBody];
UIFontDescriptor *changedFontDescriptor;
NSDictionary *attributes;
uint32_t existingTraitsWithNewTrait = [fontDescriptor symbolicTraits] | UIFontDescriptorTraitBold | UIFontDescriptorTraitItalic;
changedFontDescriptor = [fontDescriptor fontDescriptorWithSymbolicTraits:existingTraitsWithNewTrait];
UIFont *updatedFont = [UIFont fontWithDescriptor:changedFontDescriptor size:0.0];
attributes = @{ NSFontAttributeName : updatedFont };
attributedString = [[NSAttributedString alloc] initWithString:yourString attributes:attributes];