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 8427035
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T04:41:18+00:00 2026-06-10T04:41:18+00:00

I am trying to implement a sliding drawer where handler is a button/text. The

  • 0

I am trying to implement a sliding drawer where handler is a button/text.
The main reason behind that is to save space. What I hope to achieve is that the drawer would open content op top of the original view. But what actually happens is that the drawer uses a relative space (button+content) in my original view.

I hope picture below will explain it more carefully. So I have a speaker icon in the drawer as a handler. I would like it to take only those 20dp or so space. When I click on the speaker, then the drawer content overlays data below. When you click on the speaker again, the drawer closes. For now, if I emulate this case, the drawer opens/closes only in the region indicated by blue rectangle.
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-10T04:41:20+00:00Added an answer on June 10, 2026 at 4:41 am

    Judging by your screenshot, your sliding drawer is inside of a LinearLayout.

    Therefore it cannot do what you are looking for. (As the items in the LinearLayout will be listed linearly – therefore won’t overlay)

    The documentation here: http://developer.android.com/reference/android/widget/SlidingDrawer.html says you should only use the Sliding drawer in a Relative or Framelayout (as these allow overlaying):

    SlidingDrawer should be used as an overlay inside layouts. This means
    SlidingDrawer should only be used inside of a FrameLayout or a
    RelativeLayout for instance.

    I would recommend the following structure:

    Relative Layout
    -Sliding Drawer (id: slidingDrawer, aligned to parent top)
    -Linear Layout (id: contentLyout, aligned as below id:slidingDrawer)
    --TextView (id: deviceTitle)
    --ScrollView (id: contentScroll)
    ---LinearLayout (I can't see the rest of your layout)
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i'm trying to implemente a map view as a sliding drawer view from bottom
I am trying to implemment automated tests for my app. I have sliding drawer
I am trying to implement slice functionality for a class I am making that
Trying to implement some nested loops that are spitting out good old nested html
I'm trying to implement simple sliding window alogirithm on two-dimensional array in C# 3.0,
Trying to implement a function that will return a list of ints the represent
SetFocus I'm trying implement the above Se Focus code in a Class Library that
I'm trying to implement a SlidingDrawer that will occupy the full screen width, but
Ok, so I'm trying to implement a sliding video thumb gallery linked to a
I am trying to implement a similar effect like the iPhone-alike sliding header in

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.