简体   繁体   English

是否要清除有关Android多屏幕尺寸支持的所有疑问?

[英]Want to clear all doubts about Android multiple screen sizes Support?

i want to clear my all doubts about android multiple screen support. 我想清除我对android多屏支持的所有疑问。 i have searched a lot but not found any solution for it. 我已经搜索了很多,但没有找到任何解决方案。 i can clear my question by giving an example. 我可以举一个例子来澄清我的问题。

first i have a screen 480*800 and i have all image resources used in this screen with relative to this size(480*800). 首先,我有一个480 * 800的屏幕,并且我拥有此屏幕中使用的所有图像资源(相对于该尺寸(480 * 800))。 and i have created my layout using wrap_content attribute. 并且我使用wrap_content属性创建了布局。

so i want to ask where i put these image resources in drawable hdpi or mdpi or ldpi or x-hdpi. 所以我想问一下我将这些图像资源放在可绘制的hdpi或mdpi或ldpi或x-hdpi中的位置。 for example if i put these in drawable hdpi then what about other folders and other screen sizes. 例如,如果我将它们放在可绘制的hdpi中,那么其他文件夹和其他屏幕尺寸呢?

i have read all Article on developer's website but i didn't found any solution. 我已经阅读了开发人员网站上的所有文章,但未找到任何解决方案。 or where could i found a complete tutorial whit handling this issue. 或在哪里可以找到完整的教程来解决这个问题。

Thanks in advance. 提前致谢。

将这些文件用于可绘制文件夹中的所有类型的屏幕分辨率,如果要以hdpi或mdpi或ldpi或x-hdpi使用特定的屏幕大小,则必须为所有文件创建一个“可绘制”文件夹常用尺寸。

480 * 800 is a mdpi device. 480 * 800是mdpi的设备。 You can can put these image resources in drawable-mdpi if you want the device to auto adjust for smaller and larger screen sizes. 如果您希望设备针对越来越大的屏幕尺寸自动调整,则可以将这些图像资源置于drawable-mdpi中 If you want these images to be of maximum size you can put it in drawable-xhdpi . 如果您希望这些图像具有最大尺寸,则可以将其放在drawable-xhdpi中 If not ie if you want same image to be used in all the screen sizes then you can simply put in drawable folder in resource. 如果不是这样,即如果您希望在所有屏幕尺寸中使用相同的图像,则只需在资源中放入可绘制文件夹。

For more information you can check this : developer link 有关更多信息,您可以检查以下内容: 开发人员链接

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM