Search Results

Search found 2 results on 1 pages for 'uitextinput'.

Page 1/1 | 1 

  • UITextInput setMarkedText:selectedRange not working? (Can't be!)

    - by nacho4d
    I want to set the marked text programmatically and since iOS5 UITextView and UITextField conform to UITextInput this should be possible but for some reason I always get the markedText to be nil. :( What am I missing here? This is what I've tried without success: (While the textview is firstResponder) 1.- When the text view contains no text: text: "", selectedRange : {0,0}, markedText: nil. [_textView setMarkedText:@"?" selectedRange:NSMakeRange(0, 1)]; Result: text : "", selectedRange: {0,0}, markedText: nil. (Nothing changed) 2.- When the text view contains text + some marked text: text : "AAA", selectedRange = {0,3}, marked text at the end : "??" then I do: [_textView setMarkedText:@"?" selectedRangeNSMakeRange(0,3)]; Result : text :"AAA", selectedRange: {0,3}, markedText: nil; (the marked text became nil) In both cases is like setMarkedText:selectedRange: would be setting the current marked text (if some) to nil. Any help would be highly appreciated :)

    Read the article

  • dictationRecordingDidEnd never called

    - by optme
    I am using a UITextView and added UITextInputDelegate in my view controller. I have implemented textDidChange and dictationRecordingDidEnd methods. The textDidChange and dictationRecordingDidEnd are never called. Please help. In MyViewController.h file @interface MyViewController : UIViewController <UITextViewDelegate, UITextInputDelegate> { } In MyViewController.m file - (void) textDidChange:(id<UITextInput>)textInput { } - (void)dictationRecordingDidEnd { } - (void)dictationRecognitionFailed { textViewResults.text = @"Dictation Failed"; }

    Read the article

1