How does Android choose different resource under different environment settings?

Source: Internet
Author: User

How does Android choose different resource under different environment settings, for example, different language settings, different screen orientations, different screen sizes, and so on.

Generally, we will add qualifiers after those resource folder, if we add two or more qualifiers, we will add in the following order

Table 15.1 characteristics with configuration qualifiers

    1. Mobilecountrycode (MCC), Optionallyfollowedbymobilenetworkcode (MNC)

    2. Language code, optionally followed by region code

    3. Layout direction

    4. Smallest width

    5. Availablewidth

    6. Availableheight

    7. ScreenSize

    8. Screenaspect

    9. Screenorientation

    10. UI mode

    11. Night mode

    12. Screen Density (dpi)

    13. Touchscreen type

    14. Keyboard availability

    15. Primary text input

    16. Navigation Key Availability

    17. Primary Non-text Navigation method

    18. API level

You can find descriptions of these characteristics and examples of specific configuration qualifiers at HTTP://DEVELOPER.A Ndroid.com/guide/topics/resources/providing-resources.html#alternativeresources.

Similarly, after removing the resource, the Android system qualifier in the order to find the most suitable resource to use.

You can see a complete list of supported (unqualified) Res subdirectories at Http://developer.android.com/guide/topics/res Ources/providing-resources.html#resourcetypes.

From Bignerranchguide

How does Android choose different resource under different environment settings?

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.