android - TextView taking/consuming too much space above and below the text -


enter image description here

the text view encircled has space above , below text. inside text view (not above , below of it). neither used margins nor paddings remained there. xml code there.

    <tablerow         android:id="@+id/tbrow"         android:layout_width="match_parent"         android:layout_height="wrap_content"         android:layout_below="@+id/viewlineseparator"         android:layout_gravity="top"         android:layout_marginbottom="2dp"         android:layout_margintop="1dp"         android:gravity="top"         android:weightsum="1.0" >         <textview             android:id="@+id/tvreportasadult"             android:layout_width="0dp"             android:layout_height="match_parent"             android:layout_gravity="left|top"             android:layout_weight="0.60"             android:clickable="true"             android:gravity="left|top"             android:maxlines="5"             android:padding="11dp"             android:text="@string/txtreportasadulttext"             android:textcolor="#00bfff"             android:textsize="18sp" />         <linearlayout             android:layout_width="0dp"             android:layout_height="wrap_content"             android:layout_gravity="right|center"             android:layout_weight="0.40"             android:gravity="center"             android:weightsum="1.0" >              <imagebutton />             <imagebutton />             <imagebutton />             <imagebutton />          </linearlayout>     </tablerow> 

this tablerow child of relativelayout further child of scrollview. , space due textview i.e. neither due imageviews nor tablerow.

you using

  android:padding="11dp" 

which setting 11 dp padding in sides of textview. use padding separately using

paddingtop,paddingbottom,paddingleft,paddingright


Comments

Popular posts from this blog

SPSS keyboard combination alters encoding -

Add new record to the table by click on the button in Microsoft Access -

CSS3 Transition to highlight new elements created in JQuery -