Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android Widget Size

Can anyone tell me how to make a flexible AppWidgets in Android according to the screen size? I want to make a full screen widget, but when the screen size changes, I want to make it flexible.

Thanks.

like image 759
user430926 Avatar asked Oct 06 '10 11:10

user430926


People also ask

How do I resize widget?

If you want to adjust the size of an already added widget, tap and hold the required widget and then drag the border frame around it up/down and left/right to resize it. When finished, tap on an empty space on the screen to exit the edit mode. Relevant for Android versions 9.0 and higher.

What is a widget in Android?

A widget is a small gadget or control of your android application placed on the home screen. Widgets can be very handy as they allow you to put your favourite applications on your home screen in order to quickly access them.


1 Answers

I want to make a full screen widget

You cannot make a full-screen app widget.

You can create an app widget that takes up a certain number of cells, by following the instructions, which show you how to provide dimensions in dip that equate to a certain number of cells. Exactly how many cells a given home screen application will support is up to the home screen author.

In general, you want your app widget to be as small as possible, not as large as possible. A user may not have room anywhere for a large app widget.

like image 157
CommonsWare Avatar answered Nov 15 '22 23:11

CommonsWare