fill-parent Questions

9

There are a activity what I want to fill the screen in a phone and pop up(dialog) for a tablet. I thought I make a layout file like this, <LinearLayout xmlns:android="http://schemas.android....
Dripstone asked 28/7, 2011 at 12:58

6

I have this simple layout XML, and a green_square.png file which is 30X30 pixels <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/...
Hooligan asked 3/1, 2012 at 10:5

4

Solved

I'm trying to set AdMob banner ad to match it's parent width. I tried as sample: <com.google.ads.AdView android:id="@+id/ad" android:layout_width="match_parent" android:layout_height="50dp"...
Herren asked 2/9, 2013 at 23:30

8

Solved

I have a ListView which gets populated with RelativeLayouts. The content of these RelativeLayouts can change and thus change their height respectively. On each RelativeLayout, I have a little verti...
Geography asked 13/4, 2013 at 21:14

5

Solved

Hello everyone and thanks for your help. I have a project in Android Studio. I am using an ImageView inside vertical LinearLayout. Here are my parameters; <ImageView android:layout_width="f...
Dayton asked 23/9, 2014 at 12:55

2

Solved

I have a simple request: I have to put some pictures (some small resolution, some big resolution) in a dialog and display them fullscreen. I tried this: Dialog dialog = new Dialog(getActivity());...
Erythrite asked 12/1, 2012 at 9:11

1

Solved

How to stretch listview items width to fill parent container? The default behaviour seems to be squishing everything as narrow as possible.
Hemipterous asked 25/6, 2014 at 10:33

7

Solved

I have written an XML code, where I want the EditText to be expanded to fit the parent width. After spending so much time, I can not find a way to expand the EditText. Here is my XML: <?xml ve...
Latonialatoniah asked 22/7, 2012 at 20:26

1

I'm subclassing HorizontalScrollView (which is a FrameLayout) and adding a RelativeLayout to it programmatically. The FrameLayout correctly fills the parent view, but RelativeLayout inside doesn't...

5

Solved

I need a EditText that fills in height my window. I'm using this: <ScrollView xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_heigh...
Launalaunce asked 20/6, 2012 at 13:38

2

Solved

I have an ImageButton that I want to fill its parent RelativeLayout container for its width but minus a few dp so it has some left and right padding. I tried fill_parent-10dp but that causes an err...

2

Solved

What was the reason behind introducing match_parent and deprecating fill_parent since both mean the same thing. won't this change be a hindrance to backward compatibility?
Dicho asked 30/9, 2011 at 9:7

1

Solved

I am trying to add a fragment programmatically to a LinearLayout, but the fragment does not stretch its content across the whole layouts height. It acts like wrap_content instead of fill_parent. O...
1

© 2022 - 2024 — McMap. All rights reserved.