移动布局最多时显示软键盘? [英] Move layouts up when soft keyboard is shown?

查看:130
本文介绍了移动布局最多时显示软键盘?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在与对齐底部RelativeView几个元素属性设置,当软键盘出现的元素是隐藏的软键盘。

I have a few elements in a RelativeView with the align bottom attribute set, when the soft keyboard comes up the elements are hidden by the soft keyboard.

我想他们动起来,这样,如果有足够的屏幕空间,他们会显示在键盘上方,或使键盘上方的部分滚动,以便用户仍然可以看到的元素。

I would like them to move up so that if there is enough screen space they are shown above the keyboard, or to make the section above the keyboard scrollable so the user can still see the elements.

对如何处理这个任何想法?

Any ideas on how to approach this?

推荐答案

是的,检查出的这篇文章对Android开发者网站它描述了框架如何处理的软键盘出现。

Yes, check out this article on the Android developers' site which describes how the framework handles the soft keyboard appearing.

<一个href="http://developer.android.com/guide/topics/manifest/activity-element.html#wsoft">android:windowSoftInputMode属性可以用来指定在每个活动的基础上发生的事情:布局是否调整大小或者是否滚动等

The android:windowSoftInputMode attribute can be used to specify what happens on a per-activity basis: whether the layout is resized or whether it scrolls etc.

这篇关于移动布局最多时显示软键盘?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆