简体   繁体   English

如何更改首页小部件的高度?

[英]How change home widget height?

Hello :) It's possible to change height of home widget? 您好:)可以更改家庭小部件的高度吗? I know it's normal possible in XML, but I want know its possible in CLASS. 我知道在XML中这是正常的可能,但是我想在CLASS中知道它的可能。 For example, I have a widget 40dp height which gives 1 on home, and I want to have in code way to change to 110dp which gives 2 on home. 例如,我有一个高度为40dp的小部件,其高度为1,而我想以代码方式更改为110dp,其高度为2。 Any suggestions? 有什么建议么?

I don't think that it is possible. 我认为不可能。

When dragging a widget into the home screen it takes exactly the width/height specified in the xml. 将窗口小部件拖到主屏幕时,它将完全采用xml中指定的宽度/高度。

If what you wanted was possible, what would happen to the widgets arround your widget? 如果您想要的是可能的,那么围绕您的小部件的小部件会发生什么?

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

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