NSString の中から UITextview で選択したテキストを見つけるにはどうすればよいですか
//Declare
NSString* myText = @"This is the first row and This is the second row";
myUITextview.text = myText;
// we have the same results in here "This is the" and "row"
//Then check it when text in UITextview is selected
- (void)textViewDidChangeSelection:(UITextView *)textView
{
NSString *selectedText = [textView.text substringWithRange:[textView selectedRange]];
//selectedText "This is" from the second not from the first
}
とにかくそれを認識することはありますか?比較?範囲か何かを確認しますか?