Contents

textView(_:menuConfigurationFor:defaultMenu:)

Asks the delegate for the menu configuration to be performed when interacting with a text item.

Declaration

optional func textView(_ textView: UITextView, menuConfigurationFor textItem: UITextItem, defaultMenu: UIMenu) -> UITextItem.MenuConfiguration?

Parameters

  • textView:

    The text view requesting the menu.

  • textItem:

    The text item for performing said action.

  • defaultMenu:

    The default menu for the specified text item.

Return Value

Return a menu configuration to be presented when the text item is interacted with. Return @c nil to prevent the menu from being presented.

See Also

Interacting with text data