首页 > 解决方案 > Android如何选择不同维度的问题

问题描述

我是新的安卓,我有一个问题。我正在开发一个应用程序,我看到了这个问题。我为 Pixel 2 创建布局,而其他设备无法显示为 Pixel 2。当我研究时,我学习创建每个维度的布局。

我在 AndroidManifest.xml 上添加了这个

<supports-screens
    android:resizeable="true"
    android:smallScreens="true"
    android:largeScreens="true"
    android:xlargeScreens="true"
    android:normalScreens="true"
    android:anyDensity="true"/>

并创建了不同的布局;例如 login_activity.xml(正常)和 login_activity.xml(大)。但是这个屏幕如何选择设备,是自动的还是其他方式?

标签: androiddimension

解决方案


https://github.com/intuit/sdp使用它来支持多种屏幕尺寸的布局。


推荐阅读