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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T14:35:59+00:00 2026-05-25T14:35:59+00:00

I’m struggling to get a small EditText along with two buttons aligned to the

  • 0

I’m struggling to get a small EditText along with two buttons aligned to the bottom of the screen or bottom of software keyboard. Basically my problem is that every time I open up my activity (flagged with adjustResize | stateAlwaysVisible) and layout:

<LinearLayout 
xmlns:android="http://schemas.android.com/apk/res/android"
android:gravity="bottom" 
android:layout_height="match_parent" 
android:orientation="vertical" 
android:layout_width="match_parent" 
android:layout_alignParentBottom="true">

    <LinearLayout android:orientation="vertical" android:layout_height="wrap_content" android:layout_width="match_parent" android:id="@+id/soft_input_edit_placeholder">
        <EditText android:layout_width="match_parent" android:layout_height="wrap_content" android:id="@+id/editText1">
            <requestFocus></requestFocus>
        </EditText>
    </LinearLayout>
    <LinearLayout android:layout_height="wrap_content" android:layout_width="match_parent" android:weightSum="2" android:id="@+id/soft_input_layout_buttons">
        <Button android:layout_width="0dp" android:text="xxx Submit xxx" android:layout_height="wrap_content" android:id="@+id/soft_input_button_submit" android:layout_weight="1"></Button>
        <Button android:layout_width="0dp" android:text="xxx Cancel xxx" android:layout_height="wrap_content" android:id="@+id/soft_input_button_cancel" android:layout_weight="1"></Button>
    </LinearLayout>
</LinearLayout>

The keyboard slides up, it resizes the activity so that only the edit text is visible, and when I hide it (at least the keyboard has a button that allows me to hide it), layout remains in position, that is, it never slides back down, leaving half of the screen uncovered.

I read that in most cases the alignment is achieved by introducing some scalable control to the layout, but I don’t really wish to have any form of ListView there; I tried using RelativeLayout, still no go. Embedding one into the other – still no luck. I’d be very thankful for any suggestions you may have, I’m running out of ideas..

Thank you!

  • 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-25T14:35:59+00:00Added an answer on May 25, 2026 at 2:35 pm

    The problem was all in selected themes. My activity had a full-screen theme applied in the manifest (and I had no idea it might affect the view in this way); changing it to non-fullscreen has solved my problems (although it can’t be just any other theme)

    I achieved my goal by setting activity theme to Theme.Translucent and layout theme to Theme (no theme at all); applying @android:drawable/bottom_bar to the main LinearLayout and finally setting the main layout’s gravity to bottom gave me the results I was looking for.

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

Sidebar

Related Questions

link Im having trouble converting the html entites into html characters, (&# 8217;) i
I used javascript for loading a picture on my website depending on which small
Basically, what I'm trying to create is a page of div tags, each has
I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
I am currently running into a problem where an element is coming back from
I ran into a problem. Wrote the following code snippet: teksti = teksti.Trim() teksti
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I have just tried to save a simple *.rtf file with some websites and
I want to count how many characters a certain string has in PHP, but

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.