In my application, i have a UITextView with many lines, but I need the data with proper appearance.
Is it possible to have Justified Alignment in
There is solution:
NSString *text1 = @"Sample text : A his is my weblog in English, German and Korean. If you want to know more about a pizza stone once it’s cooled down.";
NSMutableParagraphStyle *style = [[NSParagraphStyle defaultParagraphStyle] mutableCopy];
[style setAlignment: kCTJustifiedTextAlignment];
NSAttributedString * subText1 = [[NSAttributedString alloc] initWithString:text1 attributes:@{
NSParagraphStyleAttributeName : style
}];
_myUiTextView.attributedText = subText1;