2013-03-25 49 views
0

如何显示只有数字和典型数学符号的键盘:圆括号,运算符(+,*,/,-,^)等。我正在寻找与iOS上的标准键盘具有相同外观和感觉的东西,可以移动,脱开和分离。我大概可以在UIView中使用按钮,但它不会像通常的键盘一样。用于数学输入的自定义键盘

+0

@MicRO双重否定使我困惑。 – alecail 2013-03-25 12:56:50

+0

一句话中的两个“不”“使逻辑”有趣“来解密 – KevinDTimm 2013-03-25 13:12:07

+1

@KevinDTimm特别是当出现”任何“,”最多“,”从不“或颜色时。 – alecail 2013-03-25 13:14:31

回答

0

UIKeyboardType

The type of keyboard to display for a given text-based view. 

typedef enum { 
    UIKeyboardTypeDefault, 
    UIKeyboardTypeASCIICapable, 
    UIKeyboardTypeNumbersAndPunctuation, 
    UIKeyboardTypeURL, 
    UIKeyboardTypeNumberPad, 
    UIKeyboardTypePhonePad, 
    UIKeyboardTypeNamePhonePad, 
    UIKeyboardTypeEmailAddress, 
    UIKeyboardTypeDecimalPad, 
    UIKeyboardTypeTwitter, 
    UIKeyboardTypeAlphabet = UIKeyboardTypeASCIICapable 
} UIKeyboardType; 

设置为按您的要求。