2017-11-22 8 views
1

Ich möchte Show Icon Menü Navigationsschublade von rechts, aber jetzt zeigen Sie von links bitte helfen?Von rechts nach links Icon Menü Navigation Schublade

<android.support.v4.widget.DrawerLayout 
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:id="@+id/drawer_layout" 
android:layout_width="match_parent" 
android:layout_height="match_parent" 
android:fitsSystemWindows="true" 
android:layout_gravity="right" 
tools:openDrawer="right"> 

<android.support.design.widget.NavigationView 
    android:id="@+id/nav_view" 
    android:layout_width="wrap_content" 
    android:layout_height="match_parent" 
    android:layout_gravity="right" 
    android:layoutDirection="rtl" 
    android:fitsSystemWindows="true" 
    app:headerLayout="@layout/nav_header_main" 
    app:menu="@menu/activity_main_drawer"/> 

enter image description here

+1

verwenden Sie arabische Sprache wenn ja, dann wird RTL (von rechts nach links) vom Android OS verwendet, um die Benutzeroberfläche automatisch zu ändern. –

Antwort

1

Versuchen das Attribut android:layout_gravity="end" innerhalb des NavigationView Element verwendet.

Verwandte Themen