c# - WP8中如何检测当前键盘书写语言

标签 c# windows-phone-8 keyboard windows-phone

我想根据用户当前的书写语言(不是电话语言)以编程方式设置 TextBlock 流向。例如,如果键盘设置为阿拉伯语,则为 RightToLeft,对于英语,则为 LeftToRight。有没有办法在 Windows Phone 8 中获取当前的键盘语言???

最佳答案

这是一个非常好的问题。

它似乎没有在 Windows Phone 8 中公开。

我在这里找到了这个 Font and language configuration support for Windows Phone

Text input

The selection of languages for which a phone has preinstalled keyboards and input method UIs is dependent on which market a phone is sold in. At any time the user can download and use a keyboard for any of the 50 supported phone client UI languages. The language of the keyboard, which determines the characters that are written to a TextBox control, is not programmatically available to an app.

有趣的是,这适用于 Windows 应用商店应用。

参见 Windows.Globalization.Language.currentInputMethodLanguageTag .

哦微软...

关于c# - WP8中如何检测当前键盘书写语言,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20029054/

相关文章:

c# - 具有特殊 F801 字符的 SQL Server nchar 和 .Net unicode

c# - 日期时间格式处理

html - 如何在 Windows 8 Phone 上访问本地 HTML 文件?

c# - 如何使用 WPF 文本框实现捕获和显示当前按键?

ios - Iphone 模拟器屏幕键盘问题

javascript - 使输入字段使用特定的键盘?有可能吗?

c# - 如何以编程方式使用 SVN 和 .NET 进行文件版本控制?

c# - 内部并在私有(private) api 中受到保护

c# - 查找导致 CannotUnloadAppDomainException 的违规线程

c - 在 Windows Phone 8 上的 taskhost 下运行的进程