简体   繁体   English

如何在 Xamarin Forms 中更改 UWP 应用的键盘布局?

[英]How to change the keyboard layout of a UWP app in Xamarin Forms?

I am working on a Xamarin Forms app which I want to deploy on Windows (UWP).我正在开发我想在 Windows (UWP) 上部署的 Xamarin Forms 应用程序。 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 xaml 代码中添加一个“键盘”属性,如下所示:

 <Entry Keyboard="Numeric" />

That does work fine in Windows Mobile Emulator and the keyboard does change as soon as I click on the entry.这在 Windows Mobile Emulator 中确实可以正常工作,并且一旦我单击该条目,键盘就会发生变化。 However, when I run the project on a Surface Pro tablet (UWP) the layout of the keyboard does not change at all.但是,当我在 Surface Pro 平板电脑 (UWP) 上运行该项目时,键盘的布局根本没有改变。

在此处输入图片说明

On tablets, no matter if it is an iPad or a surface, the Keyboard property is ignored.在平板电脑上,无论是 iPad 还是 Surface,都会忽略 Keyboard 属性。 On a phone it is not.在电话上不是。

So you have no chance to influence it on a tablet.所以你没有机会在平板电脑上影响它。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM