小部件大小在纵向上显示为3x1,在横向上显示为4x1

时间:2013-07-26 12:31:41

标签: android android-widget screen-size nexus-7

我正在为14岁以上的API版本开发一个大小为250dp x 40dp的android主屏幕小部件。

通过在我的Nexus 7上测试这个小部件,我发现当平板电脑处于纵向模式时,小部件的尺寸为3x1,但是当打开横向时它的尺寸为4x1。

见下图:

人像: enter image description here

风景: enter image description here 在nexus 10上测试它可以为两个方向提供3x1。

如何在所有方向和设备上使用相同的尺寸?

0 个答案:

没有答案