问题描述
我正在开发要在Windows(UWP)上部署的Xamarin Forms应用程序.我要解决的当前问题是在条目"上设置键盘布局.根据 docs 我唯一要做的更改是在Entry xaml代码中添加一个"keyboard"属性,如下所示:
I am working on a Xamarin Forms app which I want to deploy on Windows (UWP). The current problem I am trying to solve is to set the keyboard layout on an "Entry". According to the docs the only change I have to make is to add a "keyboard" property in the Entry xaml code like that:
<Entry Keyboard="Numeric" />
这在Windows Mobile Emulator中确实可以正常工作,并且只要我单击该条目,键盘的确会发生变化.但是,当我在Surface Pro平板电脑(UWP)上运行项目时,键盘的布局完全没有改变.
That does work fine in Windows Mobile Emulator and the keyboard does change as soon as I click on the entry. However, when I run the project on a Surface Pro tablet (UWP) the layout of the keyboard does not change at all.
推荐答案
在平板电脑上,无论是iPad还是水面,都将忽略Keyboard属性.在电话上不是.
On tablets, no matter if it is an iPad or a surface, the Keyboard property is ignored. On a phone it is not.
因此您没有机会在平板电脑上影响它.
So you have no chance to influence it on a tablet.
这篇关于如何在Xamarin Forms中更改UWP应用程序的键盘布局?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!