Solve various discomfort caused by Android soft keyboard pop-up

Source: Internet
Author: User



In the Input information page , often encounter the keyboard block the input box or some controls to the top of the situation,Android for This provides a series of configuration parameters to choose, you can Androidmanufist.xml is configured in the Windowsoftinputmode property of the corresponding Activity :




Detailed description of these four parameters:

Int

Soft_input_adjust_nothing

Adjustment option for Softinputmode:

Set to has a window not adjust for a shown input method.

Int

Soft_input_adjust_pan

Adjustment option for Softinputmode:

Set to has a window pan when an input method was shown, so it doesn ' t need to deal with resizing and just panned by

The framework to ensure, the current input, focus is visible.

Int

Soft_input_adjust_resize

Adjustment option for Softinputmode:

Set to allow the window to being resized when an-input method is shown, so it contents is not covered by the input met Hod.

Int

Soft_input_adjust_unspecified

Adjustment option for Softinputmode:

Nothing specified.

The four parameters mean the following :

Soft_input_adjust_nothing:

No adjustment ( Input method completely directly covered , not open this parameter )

Soft_input_adjust_pan:

The entire Layout on the top to reveal the focus of the EditText, do not compress the extra space .

Soft_input_adjust_resize:

Rearrange the entire Layout to reallocate extra space .

Soft_input_adjust_unspecified:

The system itself chooses the execution of the two methods according to its content ( default configuration )


Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.

Solve various discomfort caused by Android soft keyboard pop-up

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.