Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 5957367
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T18:23:27+00:00 2026-05-22T18:23:27+00:00

I have simple layout like this: (it’s for mail) <ScrollView android:layout_height=0dp android:layout_width=fill_parent android:layout_weight=1 android:background=@color/red_start>

  • 0

I have simple layout like this: (it’s for mail)

<ScrollView android:layout_height="0dp" android:layout_width="fill_parent" android:layout_weight="1" android:background="@color/red_start">

        <LinearLayout android:layout_height="fill_parent" android:layout_width="fill_parent" android:orientation="vertical" android:background="@color/blue_start">

            <TextView style="@style/MyTextViewLabel" android:text="From" android:layout_marginTop="5dp"/>

            <LinearLayout android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="wrap_content" android:background="@drawable/shape_white_rounded">
                <TextView style="@style/MyTextViewLabel.Black" android:id="@+id/tv_sender" />
            </LinearLayout>

            <TextView style="@style/MyTextViewLabel" android:text="Subject" android:layout_marginTop="5dp"/>

            <LinearLayout android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="wrap_content" android:background="@drawable/shape_white_rounded">
                <TextView style="@style/MyTextViewLabel.Black" android:id="@+id/tv_subject" />
            </LinearLayout>

            <TextView style="@style/MyTextViewLabel" android:text="Body" android:layout_marginTop="5dp"/>

            <LinearLayout android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="wrap_content" android:background="@drawable/shape_white_rounded">
                <TextView style="@style/MyTextViewLabel.Black" android:id="@+id/tv_body" />
            </LinearLayout>

        </LinearLayout>

    </ScrollView>

For some reason LinearLayout won’t fill ScrollView as I expect. Basically, I want to make tv_body to fill screen and if there is more text – it should be scrollable. Right now it looks like this. I added colors to illustrate that ScrollView stretch but LinearLayout doesn’t..

enter image description here

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T18:23:28+00:00Added an answer on May 22, 2026 at 6:23 pm

    Try to add

    android:fillViewport="true"
    

    in your ScrollView.

    Checkout this for more explanations : http://www.curious-creature.org/2010/08/15/scrollviews-handy-trick/

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a very simple Android activity layout like this: <?xml version=1.0 encoding=utf-8?> <LinearLayout
I have fairly simple layout, like this: <div class=card> <span class=attack>1</div> <span class=defence>2</div> </div>
I have a simple preference screen defined like this <PreferenceScreen xmlns:android=http://schemas.android.com/apk/res/android> <PreferenceCategory android:title=Security> <CheckBoxPreference
This is different than the simple 2 column layout. I need to have this
I have this simple Layout in my page <div id=content-wrap> <form id=form1 runat=server> <asp:ScriptManager
I have a simple HTML layout: <div style=position:relative; width:200px> <div style=position:absolute; top:0; left:0; background-color:red;
I have simple WebView code like this: WebView wv = (WebView) findViewById(R.id.webview1); wv.loadUrl(http://en.wikipedia.org/wiki/Book); But
I am trying to make a simple layout like this: --------- - - -
I have a simple layout like below (which only shows a text TEST): <?xml
I have a simple layout with a textblock and one <a> , like: text1

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.