Types a single key with the specified modifier flags.
- Xcode 7.2+
key is a string, it must represent a single key on a physical keyboard. Strings that resolve to multiple keys will raise an error at runtime.
In addition to literal string key representations like
"[", keys such as arrow keys, command, control, option, and function keys can be typed using the constants in