difference between and on Android

后端 未结 3 522
情话喂你
情话喂你 2020-11-30 10:58

I am now officially confused about the difference between the two manifest elements and

I thought that by ONLY using Google Play will filter out devices that do

3条回答
  •  刺人心
    刺人心 (楼主)
    2020-11-30 11:48

    Description

    1.support-screens

    It lets you specify the screen sizes your application supports and enable screen compatibility mode for screens larger than what your application supports. An application "supports" a given screen size if it resizes properly to fill the entire screen. Normal resizing applied by the system works well for most applications and you don't have to do any extra work to make your application work on screens larger than a handset device. However, it's often important that you optimize your application's UI for different screen sizes by providing alternative resources (layouts, drawables, images etc).

     
    

    If your application does not support large and xlarge exclusively, system's screen compatibility mode would scale up ("zoom") UI to fit larger screens . Since you have not designed for larger screen sizes and the normal resizing does not achieve the appropriate results, screen compatibility mode will scale your UI by emulating a normal size screen and medium density, then zooming in so that it fills the entire screen.However this causes pixelation and blurring of your UI.

    2.compatible-screens

    It specifies each screen configuration with which the application is compatible. Only one instance of the element is allowed in the manifest, but it can contain multiple elements. Each element specifies a specific screen size-density combination with which the application is compatible. Any screen configuration that is not declared in this element is a screen with which the application is not compatible.

    Difference

    a) support-screens

    1. Basically the Android system itself read the manifest element and then enables screen compatibility mode.

    2. It's important that you always use this element in your application to specify the screen sizes your application supports.

    b) compatible-screens

    1. The Android system does not read the manifest element (neither at install-time nor at runtime). This element is informational only and may be used by external services (such as Google Play) to better understand the application's compatibility with specific screen configurations and enable filtering for users.

    2. Normally, you should not use this manifest element. Using this element can dramatically reduce the potential user base for your application, by not allowing users to install your application if they have a device with a screen configuration that you have not listed. You should use it only as a last resort, when the application absolutely does not work with specific screen configurations.

提交回复
热议问题