title: How can I achieve AutoCompleteTextView at bottom of the screen?
body: <p>I am trying to have an AutoCompleteTextView at the bottom of the screen but its behavior is inconsistent and confusing. I had achieved it somehow but I changed some code I am unable to trace and now while typing, drowpdown covers the text input area and gets cut in height. and when keyboard is dismissed, the result is closer to what I want but it's still shorter in height. what I want to achieve is the blue area in the screenshots</p>
  
  <p><a href="https://i.stack.imgur.com/RKK6K.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/RKK6K.png" alt="typing abcd"></a></p>
  
  <p><a href="https://i.stack.imgur.com/pRiJ8.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/pRiJ8.png" alt="scrolling the dropdown list"></a></p>
  
  <p>activity_main:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
  xmlns:app="http://schemas.android.com/apk/res-auto"
  xmlns:tools="http://schemas.android.com/tools"
  android:orientation="vertical"
  android:layout_width="match_parent"
  android:layout_height="match_parent"
  android:id="@+id/layout_main"&gt;
  
  
  &lt;RelativeLayout
      android:layout_width="match_parent"
      android:layout_height="wrap_content"
      android:background="@color/colorPrimary"
      android:id="@+id/h"&gt;
  
      &lt;ImageView
          android:id="@+id/button_nav"
          android:layout_width="36dp"
          android:layout_height="36dp"
          android:layout_alignParentStart="true"
          android:scaleType="fitCenter"
          android:src="@drawable/ic_menu_white_48dp"
          android:layout_margin="16dp" /&gt;
      &lt;TextView
          android:id="@+id/title"
          android:layout_width="match_parent"
          android:layout_height="68dp"
          android:layout_gravity="center"
          android:text="@string/app_name"
          android:textAlignment="center" /&gt;
  &lt;/RelativeLayout&gt;
  
  &lt;androidx.drawerlayout.widget.DrawerLayout
      android:id="@+id/drawer_layout"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      android:layout_below="@+id/h"
      tools:openDrawer="start"&gt;
  
  
  
          &lt;LinearLayout
              android:layout_width="match_parent"
              android:layout_height="match_parent"
              android:orientation="horizontal"
              android:layout_marginBottom="8dp"
              android:gravity="bottom"&gt;
              &lt;androidx.appcompat.widget.AppCompatAutoCompleteTextView
                  android:layout_width="0dp"
                  android:layout_weight="1"
                  android:layout_height="wrap_content"
                  android:dropDownHeight="match_parent"
                  android:id="@+id/edit_link_or_username"
                  android:inputType="text|textUri"
                  android:imeOptions="actionNext"
                  android:hint="@string/hint_enter_link_or_username" /&gt;
              &lt;FrameLayout
                  android:layout_width="wrap_content"
                  android:layout_height="wrap_content"
                  android:layout_marginEnd="4dp"&gt;
                  &lt;ImageButton
                      android:layout_width="50dp"
                      android:layout_height="50dp"
                      android:id="@+id/button_confirm"
                      android:src="@drawable/ic_search_white_48dp"
                      android:visibility="visible"/&gt;
                  &lt;ProgressBar
                      android:layout_width="50dp"
                      android:layout_height="50dp"
                      android:id="@+id/progress_link_or_username"
                      android:visibility="invisible" /&gt;
              &lt;/FrameLayout&gt;
  
          &lt;/LinearLayout&gt;
      &lt;com.google.android.material.navigation.NavigationView
          android:id="@+id/nav_view"
          android:layout_width="wrap_content"
          android:layout_height="match_parent"
          android:layout_gravity="start"
          android:fitsSystemWindows="true"
          app:headerLayout="@layout/nav_header_main"
          app:menu="@menu/activity_main_drawer"
          tools:visibility="gone" /&gt;
  &lt;/androidx.drawerlayout.widget.DrawerLayout&gt;
  </code></pre>
  
  <p></p>