开发者

Specifying virtual keyboard type for EditText in XML

I'm creating a ListActivity. In each list item I have a View I've created which contains a RatingBar and an EditText. In the screenshot at the bottom, you can see the virtual keyboard contains a returnline key and no "Done" key. I would开发者_StackOverflow社区 like to specify a different style of keyboard to use (and hopefully retain the spell checking bar). I would like my virtual keyboard to have a "Done" key instead of a return key. Can I set the style of virtual keyboard I'm wanting in the EditText's XML? If so, how?

Thanks for your help

Specifying virtual keyboard type for EditText in XML


Try android:imeOptions or TextView#setImeOptions(). Check the docs.


It would appear

android:inputType="textImeMultiLine|textAutoCorrect"

does mostly what I want. It only allows me to have my EditText be 1 row, though.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜