[英]Different icon sizes on different devices with the same resolution and dpi
I'm testing my app on 2 devices - a Samsung Galaxy S3 and a Samsung Galaxy Note 2. Both have the same screen resolution and apparently both use the same xhdpi density even though the Note 2 has a considerably lower physical dpi. 我正在2种设备上测试我的应用程序-三星Galaxy S3和三星Galaxy Note2。尽管Note 2的物理dpi相当低,但它们都具有相同的屏幕分辨率,而且显然都使用相同的xhdpi密度。
My icons on the action bar look smaller on the S3 than on the Note 2. Why is this so, and how can I fix it so that it looks consistent? 在S3上,操作栏上的图标看起来比在Note 2上小。为什么是这样,以及如何对其进行修复以使其看起来一致?
Samsung Galaxy S3 三星Galaxy S3
Samsung Galaxy Note 2 三星Galaxy Note 2
It turns out that even though the resolutions I was using for the individual pixel densities were correct, the actual icon area within the image file had an incorrect size. 事实证明,即使我为各个像素密度使用的分辨率是正确的,图像文件中的实际图标区域的大小也不正确。 I followed this guide at iconhandbook.co.uk/reference/chart/android/ and now things look consistent. 我在iconhandbook.co.uk/reference/chart/android/上遵循了该指南,现在看起来很一致。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.