2013-08-23 36 views
7

khi viết nội dung bằng tiếng Ả Rập bên trong TextView từ đầu tiên trong mỗi dòng sẽ cắt !!cắt nội dung trong TextView

sự cố này chỉ xảy ra khi tôi đặt kiểu chữ thành TextView!

cuttig

đây đang xml tôi

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 
android:layout_width="match_parent" 
android:layout_height="match_parent" 
android:orientation="vertical" > 
<TextView 
    android:layout_width="fill_parent" 
    android:layout_height="wrap_content" 
    android:scrollbars="vertical" 
    android:id="@+id/articleTEXT" 

    /> 

lưu ý: nội dung sẽ lấy từ cơ sở dữ liệu SQLite.

+0

thử thêm đệm có thể là nó giúp – KOTIOS

+1

Không phải là arabic "ngược" so với tiếng Anh? Bạn cần hướng văn bản phải không? – ChiefTwoPencils

+1

^Tốt bắt @BobbyDigital –

Trả lời

0

Hãy thử này ...

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 
android:layout_width="match_parent" 
android:layout_height="match_parent" 
android:orientation="vertical" 
    android:padding="10dp" 
> 
<TextView 
    android:layout_width="fill_parent" 
    android:layout_height="wrap_content" 
    android:scrollbars="vertical" 
    android:id="@+id/articleTEXT" 

    /> 
1

Nó sẽ làm việc, thêm đệm trong cách bố trí tuyến tính và lấy chiều rộng của trận đấu TextView mẹ.

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 
      xmlns:tools="http://schemas.android.com/tools" 
      android:layout_width="match_parent" 
      android:layout_height="match_parent" 
      android:orientation="vertical" 
      android:padding="4dp"> 

      <TextView 
       android:id="@+id/articleTEXT" 
       android:layout_width="match_parent" 
       android:layout_height="wrap_content" 
       android:scrollbars="vertical" 
      /> 

     </LinearLayout> 
0

Đặt trọng lực sang phải trong chế độ xem văn bản và sau đó đặt paddingRight thành 20dp.

Hoặc chỉ cần đặt padding=30dp trong linearlayout của bạn.

0

Hãy thử điều này

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 
android:layout_width="match_parent" 
android:layout_height="match_parent" 
android:orientation="vertical" 
android:layout_margin="5dp"> 
<TextView 
    android:layout_width="fill_parent" 
    android:layout_height="wrap_content" 
    android:scrollbars="vertical" 
    android:id="@+id/articleTEXT" 
    android:padding="5dp" 
/> 
1

Bạn có thể thử đặt này trong LinearLayout hoặc TextView của bạn:

android:layout_marginRight="20dp" 
Các vấn đề liên quan