Force Android widget to span full screen width
I'm having a hard time getting this to work. The Android documentation, while seemingly straightforward, doesn't get me where I need to be.
What I want to do is my widget should be the width of the phone regardless of form factor
I need it to be 4 x 1 (or 4 x 2 is fine) ... but it needs to fill the width.
<appwidget-provider xmlns:android="http://schemas.android.com/apk/res/android"
android:minWidth="250dp"
android:minHeight="100dp"
android:previewImage="@drawable/main_app_icon"
android:initialLayout="@layout/initial_widget_layout"
android:updatePriodMillis="0"/>
I understand that minHeight is wrong. Can you also offer some guidance on this?
Thank.
EDIT: While I understand that there are a number of threads talking about widgets, I can't find one that explains how to get the widget to fill the full width of the screen.
+3
source to share
1 answer