您可以为从右到左的语言定义其他布局。您应该将其放置到您的语言代码>的布局<。
如果字符串太大,也可以截断并替换字符串的最后一个字符。 你可以做到这一点采用了android:ellipsize和android:单线属性:
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/text_mytext"
android:ellipsize="end"
android:singleLine="true"
/>
另一种方法是定义dimens.xml文字大小需要语言和按如下方式使用它:
在dimens.xml
:
<dimen name="text_size">32sp</dimen>
布局:
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/text_mytext"
android:textSize="@dimen/text_size"
/>
安置自己的布局,你的代码 –