• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Supports-Screens

BlinkXIO

Lurker
Hey I have been learning about developing games for Andriod and I just wanted check some information becuase it's not 100% clear.

Firstly the bellow two links from the Andriod Developer website both show declaring support in a different way.

The first one:

https://developer.android.com/guide/topics/manifest/supports-screens-element.html#compat-mode

Code:
<supports-screens android:resizeable=["true"| "false"]
                  android:smallScreens=["true" | "false"]
                  android:normalScreens=["true" | "false"]
                  android:largeScreens=["true" | "false"]
                  android:xlargeScreens=["true" | "false"]
                  android:anyDensity=["true" | "false"]
                  android:requiresSmallestWidthDp="integer"
                  android:compatibleWidthLimitDp="integer"
                  android:largestWidthLimitDp="integer"/>

The second one:

https://developer.android.com/guide/topics/manifest/compatible-screens-element#screenSize

Code:
<compatible-screens>
        <!-- all small size screens -->
        <screen android:screenSize="small" android:screenDensity="ldpi" />
        <screen android:screenSize="small" android:screenDensity="mdpi" />
        <screen android:screenSize="small" android:screenDensity="hdpi" />
        <screen android:screenSize="small" android:screenDensity="xhdpi" />
        <screen android:screenSize="small" android:screenDensity="xxhdpi" />
        <screen android:screenSize="small" android:screenDensity="xxxhdpi" />
        <!-- all normal size screens -->
        <screen android:screenSize="normal" android:screenDensity="ldpi" />
        <screen android:screenSize="normal" android:screenDensity="mdpi" />
        <screen android:screenSize="normal" android:screenDensity="hdpi" />
        <screen android:screenSize="normal" android:screenDensity="xhdpi" />
        <screen android:screenSize="normal" android:screenDensity="xxhdpi" />
        <screen android:screenSize="normal" android:screenDensity="xxxhdpi" />
    </compatible-screens>

Is there any real difference between the two other than that the first dose not specify density?

Second I wanted to just make sure I understand what exactly constitutes as a Small, Normal, Large and xLarge screen.

Please correct me on this:
A Normal screen is a HVGA 480x320 pixels screen. This value is the baseline for that other screen sizes.

A Large screen would be 1.5x the normal baseline.

A XLarge screen would be 2x that baseline.

and so on...
 
Back
Top Bottom