iOS 7.1 UITextView still not scrolling to cursor/caret after new line
Improved solution’s code for UITextView descendant class: #define SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(v) ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] != NSOrderedAscending) #define is_iOS7 SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(@”7.0″) #define is_iOS8 SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(@”8.0″) @implementation MyTextView { BOOL settingText; } – (id)initWithFrame:(CGRect)frame { self = [super initWithFrame:frame]; if (self) { [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(handleTextViewDidChangeNotification:) name:UITextViewTextDidChangeNotification object:self]; } return self; } – (void)scrollToCaretInTextView:(UITextView *)textView animated:(BOOL)animated { CGRect rect … Read more