Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>One thing i noticed is you use a lot of hardcoded dimensions,is that really necesary? using wrap_content would be better practice on most layouts,that way you let android handle it. As far as your question is concerned you can do two things: 1)Your two EditTexts are inside a relative layout,and if customMsg is 4 lines long,it will get scrolled ,and you'll loose your uNameTxt so you should limit customMsg more,to something like two lines,or less. OR if you are ok with loosing some parts of the code you could adapt your layout this way</p> <pre><code> &lt;TextView android:id="@+id/uNameTxt" android:layout_width="fill_parent" android:layout_height="wrap_content" layout_alignParentTop="true" android:minHeight="?android:attr/listPreferredItemHeight" android:singleLine="true" android:textAppearance="?android:attr/textAppearanceMedium" android:textSize="@dimen/fontSizeListRowHeader" /&gt; &lt;TextView android:id="@+id/customMsg" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_below="@+id/uNameTxt" android:maxLines="4" android:textSize="@dimen/fontSizeListRowText" android:textStyle="italic" /&gt; </code></pre> <p>it should scroll down no more and you should see Name and a part of customMsg</p> <p>2)Edit your layout to something more efficient like:</p> <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt; &lt;RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent" android:minHeight="56dp"&gt; &lt;ImageView android:id="@+id/icon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="4dp" android:layout_marginRight="15dp" android:contentDescription="sasd" &gt; &lt;/ImageView&gt; &lt;TextView android:id="@+id/uNameTxt" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_alignParentTop="true" android:singleLine="true" android:layout_toRightOf="@+id/icon" android:textSize="@dimen/fontSizeListRowHeader" android:textAppearance="?android:attr/textAppearanceMedium" /&gt; &lt;TextView android:id="@+id/customMsg" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_below="@+id/uNameTxt" android:maxLines="2" android:layout_toRightOf="@+id/icon" android:textSize="@dimen/fontSizeListRowText" android:textStyle="italic" /&gt; &lt;/RelativeLayout&gt; </code></pre>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload