When a UTextField becomes first responder is there a way to instruct the keyboard to use the auto-capitalise mode?
I thought the Settings -> General -> Keyboard -> Auto-Capitalisation setting might be controlling this behaviour but my iOS device and the simulator both have this enabled and it does not seem to have any effect.
The
UITextFieldconforms to theUITextInputTraitsprotocol. Through that protocol, you can set theautocapitalizationTypeproperty of theUITextFieldto influence the capitalization behavior.For example, if you want all characters to be capitalized by default, try the following when you initialize your text field (like in your viewDidLoad method):