SORU
4 ŞUBAT 2010, PERŞEMBE


Android TextView Metin sarılmış almıyorum

Herkes metin ile yanlış giden şeyin ne olduğunu bana söyleyebilir misiniz? Metin bir satır daha uzun bir sonraki satıra atlamaz ama ekranın ötesine geçer.

Takip kodu:

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="fill_parent" 
    android:layout_height="wrap_content"
    android:orientation="horizontal" 
    android:padding="4dip">

    <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
        android:layout_width="fill_parent" 
        android:layout_height="wrap_content"
        android:orientation="vertical" 
        android:padding="4dip">

        <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
            android:layout_width="fill_parent" 
            android:layout_height="wrap_content"
            android:orientation="horizontal" 
            android:padding="4dip">
            <TextView 
                android:id="@ id/reviewItemEntityName"
                android:layout_width="wrap_content" 
                android:layout_height="wrap_content"
                android:text="event/venue" 
                android:textColor="@color/maroon"
                android:singleLine="true" 
                android:ellipsize="end" 
                android:textSize="14sp"
                android:textStyle="bold" 
                android:layout_weight="1" />

            <ImageView 
                android:id="@ id/reviewItemStarRating"
                android:layout_width="wrap_content" 
                android:layout_height="wrap_content"
                android:layout_alignParentTop="true"
                android:layout_alignParentBottom="true"
                android:src="@drawable/title_1_star" />
        </LinearLayout>

        <TextView 
            android:id="@ id/reviewItemDescription"
            android:layout_width="fill_parent" 
            android:layout_height="wrap_content"
            android:text="Description comes here" 
            android:textSize="12sp" 
            android:layout_weight="1"/>
    </LinearLayout>
</LinearLayout>

CEVAP
4 ŞUBAT 2010, PERŞEMBE


Kendim tamir ettim, anahtarı android:width="0dip"

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
 android:layout_width="fill_parent" android:layout_height="wrap_content"
 android:padding="4dip">

 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
  android:layout_width="wrap_content" android:layout_height="wrap_content"
  android:orientation="vertical" android:padding="4dip"
  android:layout_weight="1">

  <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
   android:layout_width="fill_parent" android:layout_height="wrap_content"
   android:orientation="horizontal" android:padding="4dip">
   <TextView android:id="@ id/reviewItemEntityName"
    android:layout_width="wrap_content" android:layout_height="wrap_content"
    android:textColor="@color/maroon" android:singleLine="true"
    android:ellipsize="end" android:textSize="14sp" android:textStyle="bold"
    android:layout_weight="1" />

   <ImageView android:id="@ id/reviewItemStarRating"
    android:layout_width="wrap_content" android:layout_height="wrap_content"
    android:layout_alignParentTop="true"
    android:layout_alignParentBottom="true" />
  </LinearLayout>

  <TextView android:id="@ id/reviewItemDescription"
   android:layout_width="fill_parent" android:layout_height="wrap_content"
   android:textSize="12sp" android:width="0dip" />
 </LinearLayout>


 <ImageView android:id="@ id/widget01" android:layout_width="wrap_content"
  android:layout_height="wrap_content" android:src="@drawable/arrow_nxt"
  android:layout_gravity="center_vertical" android:paddingRight="5dip" />

</LinearLayout>

Bunu Paylaş:
  • Google+
  • E-Posta
Etiketler:

YORUMLAR

SPONSOR VİDEO

Rastgele Yazarlar

  • fufko

    fufko

    27 ŞUBAT 2006
  • Jabari Johnson

    Jabari Johns

    18 Ocak 2008
  • pleated-jeans

    pleated-jean

    6 HAZİRAN 2013