在Android Studio中支持RTL的最佳实践是什么?还是应该创建一个专门用于英语和阿拉伯语的分离布局?
<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView
android:text="@string/CourseName"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/textView7"
android:layout_marginTop="16dp"
app:layout_constraintTop_toTopOf="parent"
android:layout_marginStart="16dp"
app:layout_constraintLeft_toLeftOf="parent"
android:layout_marginLeft="16dp"
android:textAppearance="@style/TextAppearance.AppCompat.Display1" />
<Button
android:text="@string/enroll"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/button"
android:layout_marginTop="16dp"
app:layout_constraintTop_toTopOf="parent"
android:layout_marginEnd="16dp"
app:layout_constraintRight_toRightOf="parent"
android:layout_marginRight="16dp"
android:textAppearance="@style/TextAppearance.AppCompat.Display2" />
</android.support.constraint.ConstraintLayout>
...Start
е’Ң...End
规еҲҷиҖҢдёҚжҳҜ...Left
е’Ң...Right
规еҲҷгҖӮ - CommonsWareConstraintLayout
具有layout_constraintStart_toEndOf
、layout_constraintStart_toStartOf
、layout_constraintEnd_toStartOf
和layout_constraintEnd_toEndOf
属性,与我的评论一致。 - CommonsWare