0

我已经在Navigation Drawer背景中放置了图像。图像在那里,但它不适合在视图中的完整图像,图像的上部部分图像的5%未进入视图,这是主要部分,我希望它在背景中。如何在导航抽屉背景中显示完整图像

这是我的代码。

<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:layout_width="match_parent" 
    android:layout_height="match_parent" 
    android:fitsSystemWindows="true" 
    tools:context="com.myapp.HomeActivity" 
    android:id="@+id/drawer_layout_main" 
    > 
    <android.support.design.widget.NavigationView 
     android:layout_width="wrap_content" 
     android:layout_height="match_parent" 
     android:id="@+id/navigation_view" 
     android:layout_gravity="start" 
     android:background="@drawable/sidebg" 
     android:gravity="bottom|left" 
     android:dividerHeight="0dp" 
     app:itemIconTint="@android:color/white" 
     android:scaleType="fitStart" 
     > 

     <include layout="@layout/navigation_items"/> 

    </android.support.design.widget.NavigationView> 


</android.support.v4.widget.DrawerLayout> 

请引导我如何在导航抽屉背景中显示完整图像。

+0

你有没有尝试添加'机器人:fitsSystemWindows =“真”''到'? – kimbaudi

+0

只是累了,但没有成功 – Kirmani88

+0

你有没有修好? –

回答

0

这不是一个合适的答案,但你可以做的是减少文件的大小,然后应用

+0

没有代码,您可以在某个编辑器中更改图像的大小,然后应用。 –

+0

好的,是坏的适度抱歉 – GGO