在我的应用程序中,我已经实现了一些语言,包括从右到左开始的阿拉伯语。我想将工具栏中的所有图标对齐为
RIGHT_TO_LEFT
。我尝试过layout_gravity="right"
和gravity="right"
,但什么都没有发生。我的工具栏代码:<android.support.v7.widget.Toolbar
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/toolbar"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@color/primary_color"
app:popupTheme="@style/Theme.AppCompat.Light"/>
这是我想要的: