0

I need to get the targetRect of the [UIMenuController sharedMenuController]. I already try this:

[UIMenuController sharedMenuController] addObserver:self forKeyPath:@"targetRect" :NSKeyValueObservingOptionNew context:NULL];
Nathan Villaescusa
  • 17,331
  • 4
  • 53
  • 56
Alejandro Cotilla
  • 2,501
  • 1
  • 20
  • 35

1 Answers1

0

Are you trying to get this for a UITextView or UIWebView? If it is UITextView, this answer might help you.

How can I get the selected text frame from a UITextView

You can't get the actual targetRect since it is declared private in UIMenuController.

Community
  • 1
  • 1
Chris Savory
  • 2,597
  • 1
  • 17
  • 27