如何在iOS键盘上显示美国手语(手势)?

在这里输入图像说明 我必须创build一个支持美国手语的自定义键盘。 为此,我必须将英文键盘的键符号转换为美国手语符号键。 所以如何在iOS键盘上将(英文字母)翻译成ASL-(手形符号)。

看看这个: 如何模拟IOS中的手语键盘?

我们必须做相反的事情。 即键盘上的手势。 而当用户按手势键字母它尊重的字母将出现在文本编辑器中。

提示:手语支持字体。 而且我使用“Gallaudet-Regular”字体在键盘按键上绘制手形符号。 但不能做到这一点。

注 – 下面是在iOS中创build自定义键盘扩展的代码。 当你使用下面的代码,它会创build一个键手按键上的button,但是当我用来点击键盘键时,它给出了“a”作为文本,但我想手标志,当我点击。

代码:第1步://创build一个自定义button

self.testingButton = UIButton.buttonWithType(.System) as UIButton self.testingButton.setTitle(NSLocalizedString("a", comment: "Title for 'First Keyboard' button"), forState: .Normal) self.testingButton.sizeToFit() self.testingButton.titleLabel?.font = UIFont(name: "Gallaudet-Regular", size: 50) self.testingButton.backgroundColor = UIColor.redColor() self.testingButton.setTranslatesAutoresizingMaskIntoConstraints(false) self.testingButton.addTarget(self, action: "tapKeyboardButton:", forControlEvents: .TouchUpInside) self.view.addSubview(self.testingButton) 

第2步:/ /执行buttonselect器上的操作

func tapKeyboardButton(sender:UIButton){

  let title = sender.titleForState(UIControlState.Normal) var proxy = textDocumentProxy as UITextDocumentProxy proxy.insertText(title!) } 

我希望button标题是手动login文本编辑器。

您应该尝试安装http://www.lifeprint.com/asl101/pages-layout/gallaudettruetypefont.htm字体并将字体设置更改为Gallaudettruetype字体。 这应该可以解决问题。 尽pipe我不是iOS开发人员,但可以帮助您理解logic

Update:如果你可以在你的设备(iPhone,iPad)上安装该字体,那么你也应该能够改变inputtypes(键盘)。 这将完全解决您的问题。 我不确定你将如何做到这一点,但这应该是逻辑,你应该朝这个方向前进。

Interesting Posts