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

  • SEARCH
  • Home
  • 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 8169045
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T20:43:35+00:00 2026-06-06T20:43:35+00:00

I want to implement a collapsible view, exactly like the one from Google Play

  • 0

I want to implement a collapsible view, exactly like the one from Google Play market. It displays a number of rows from the content, and an arrow, and tapping on the arrow reveals the whole content. Is this implemented with the ExpandableListView or is there any other solution?

Screen shots attached with highlighting what I am looking for.
Thanks.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-06-06T20:43:37+00:00Added an answer on June 6, 2026 at 8:43 pm

    There is a simpler way:

            final TextView descriptionText = (TextView) view.findViewById(R.id.detail_description_content);
            final TextView showAll = (TextView) view.findViewById(R.id.detail_read_all);
            showAll.setOnClickListener(new OnClickListener() {
                @Override
                public void onClick(View v) {
                    showAll.setVisibility(View.INVISIBLE);
    
                    descriptionText.setMaxLines(Integer.MAX_VALUE);
                }
            });
    

    XML:

    <?xml version="1.0" encoding="utf-8"?>
    <ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
        android:layout_width="match_parent"
        android:layout_height="match_parent">
        <LinearLayout
            android:id="@+id/detail_description_container"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:orientation="vertical"
            >
    
            <TextView
                android:id="@+id/detail_description_content"
                android:maxLines="5"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"/>
            <TextView
                android:id="@+id/detail_read_all"
                android:clickable="true"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"/>
        </LinearLayout>
    </ScrollView>
    

    The important part is maxlines and scrollview. This doesn’t give a slow animation (that would be a bid more complex) but an instant open effect.

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

Sidebar

Related Questions

I want to implement a collapsible menu. I plan to use table component to
I wrote small service class and I want implement something like that : service
want to implement poor man's ssl only to encrypt certain fields of only one
I want to implement a minor file system like collection in MongoDB . So
I want to implement email application which has all options like inbox,compose,drafts and etc.
I want to implement a splash screen in my application, like if the username
I want to implement caching of a list pulled from the db. I've had
I Want Implement a Software by C#.net.I want Use a DataBase Manager Software like
I want to implement an ISAPI filter like feature using HttpModule in IIS7 running
i want implement geolocation notification like the app reminders. this is what i have

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.