不支持多个屏幕尺寸的Andr​​oid [英] Can't support multiple screen sizes Android

查看:145
本文介绍了不支持多个屏幕尺寸的Andr​​oid的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要一些帮助与设计Android中的多个屏幕尺寸。

我创建的布局,布局sw600dp,价值观和价值观sw600dp与维度布局sw600dp dimens.xml文件。

但是,当我与7平板电脑模拟器上运行的应用程序,设计设置不正确。

我该如何解决这个问题?


解决方案

  

画面的基本大小,可用的屏幕区域的最短尺寸如图所示。具体而言,该器件的最小宽度是最短的屏幕的可用高度和宽度(你也可以认为它是最小宽度可能为屏幕)的。你可以使用这个限定词,以确保,无论画面当前的方向,你的应用具有可供其UI宽度至少DPS。 设备的smallestWidth不改变屏幕的方向变化时。


尝试使用布局w600dp 而不是 SW

I need some help with design for multiple screen sizes in Android.

I created layout, layout-sw600dp, values, and values-sw600dp with dimens.xml file with dimension for layout-sw600dp.

But when I run application in emulator with 7" tablet, the design is not set up properly.

How I can fix this?

解决方案

The fundamental size of a screen, as indicated by the shortest dimension of the available screen area. Specifically, the device's smallestWidth is the shortest of the screen's available height and width (you may also think of it as the "smallest possible width" for the screen). You can use this qualifier to ensure that, regardless of the screen's current orientation, your application has at least dps of width available for its UI. the device's smallestWidth does not change when the screen's orientation changes.

Try to use layout-w600dp instead of sw.

这篇关于不支持多个屏幕尺寸的Andr​​oid的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆