title: Android: How to set EditText and Button to same height?
body: <p>I want to make the EditText and the OK button same height, but always got the EditText slightly shorter than the Button.</p>
  
  <p><img src="https://i.stack.imgur.com/JXplc.png" alt="enter image description here"></p>
  
  <p>I googled and tried the following way without succeed, nothing changed:</p>
  
  <ol>
  <li>set both the EditText and Button to same height in pixel</li>
  <li>wrap EditText and Button into a RelativeLayout. Set the height of the RelativeLayout and set EditText and Button both to fillparent in height</li>
  <li>set alignTop and alignBottom on the Button</li>
  </ol>
  
  <p>The theme is: <code>android:theme="@android:style/Theme.NoTitleBar.Fullscreen</code></p>
  
  <p>Could someone please help me on this? Thanks!</p>
  
  <p>Here is the xml:</p>
  
  <pre><code>&lt;RelativeLayout android:id="@+id/login_layout_ipAddr"
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:layout_centerInParent="true"
          android:background="#CEE6F0"
          android:visibility="invisible"&gt;
  
          &lt;RelativeLayout android:id="@+id/login_layout_inner_ipAddr"
              android:layout_width="wrap_content"
              android:layout_height="wrap_content"&gt;
  
              &lt;EditText android:id="@+id/login_text_ipAddr"
                  android:layout_width="wrap_content"
                  android:layout_height="fill_parent"
                  android:inputType="text"
                  android:textSize="5pt"
                  android:hint="@string/login_text_ipAddr" /&gt;
  
              &lt;Button android:id="@+id/login_btn_ipAddr"
                  android:layout_width="wrap_content"
                  android:layout_height="fill_parent"
                  android:background="#00ABDF"
                  android:textColor="#FFFFFF"
                  android:text="@string/login_btn_ipAddr"
                  android:onClick="updateIPaddr"/&gt;
  
          &lt;/RelativeLayout&gt;
  
  
      &lt;/RelativeLayout&gt;
  </code></pre>