0

how can I get the current text input state to toggle between email field, browser url field or text field. I want to display @ signs, open button or enter button depending on the current state. I searches and tried for days but could not find anything.

-- best regards

Andrew
  • 15,357
  • 6
  • 66
  • 101
zeiteisen
  • 7,078
  • 5
  • 50
  • 68

1 Answers1

1

You don't have direct access to the user's text field.

However, you have access via the text document proxy, which conforms to UITextInputTraits.

In your KeyboardViewController, you want to use self.textDocumentProxy's following properties: returnKeyType and keyboardType

nurnachman
  • 4,468
  • 2
  • 37
  • 40