我想根据用户当前的书写语言(不是电话语言)以编程方式设置 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/