码迷,mamicode.com
首页 > 移动开发 > 详细

iOS学习之键盘类型UIKeyboardType

时间:2016-06-11 21:23:09      阅读:195      评论:0      收藏:0      [点我收藏+]

标签:

关于 UITextField 的键盘是可以自定义的,正好在一个代码用这个,就总结一下。

UITextField 中有一个 keyboardType 属性,它的类型是一个枚举值,下面就是枚举值和对应的键盘样式

UIKeyboardTypeDefault  // Default type for the current input method.

技术分享

UIKeyboardTypeASCIICapable  // Displays a keyboard which can enter ASCII characters, non-ASCII keyboards remain active 技术分享

UIKeyboardTypeNumbersAndPunctuation  // Numbers and assorted punctuation.

技术分享

UIKeyboardTypeURL  // A type optimized for URL entry (shows . / .com prominently).

技术分享

UIKeyboardTypeNumberPad  // A number pad (0-9). Suitable for PIN entry.

技术分享

UIKeyboardTypePhonePad  // A phone pad (1-9, *, 0, #, with letters under the numbers).

 技术分享

UIKeyboardTypeNamePhonePad  // A type optimized for entering a person‘s name or phone number.

技术分享

UIKeyboardTypeEmailAddress  // A type optimized for multiple email address entry (shows space @ . prominently).

技术分享

UIKeyboardTypeDecimalPad  // A number pad with a decimal point.

技术分享

UIKeyboardTypeTwitter  // A type optimized for twitter text entry (easy access to @ #)

技术分享

UIKeyboardTypeWebSearch  // A default keyboard type with URL-oriented addition (shows space . prominently).

技术分享

UIKeyboardTypeAlphabet = UIKeyboardTypeASCIICapable, // Deprecated

技术分享

iOS学习之键盘类型UIKeyboardType

标签:

原文地址:http://www.cnblogs.com/gfxxbk/p/5575908.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!