can I add an image header in navigation drawer layout

前端 未结 2 1495
一整个雨季
一整个雨季 2021-01-24 20:06

how can i add an image header to my navigation drawer layout like this one

\"enter

<
2条回答
  •  孤独总比滥情好
    2021-01-24 20:12

    In the Navigation Drawer layout xml file. Above drawerView and inside your parent layout add an image view as shown below:

    
    

    This should be sufficient. Hope this helps.

    Use Recycler View to create a navigation drawer. Recycler view is used most now. In your navigation drawer fragment have your layout file as shown below. This make you achieve your objective:

    
    
    
        
    
    
        
    
    
    
    

提交回复
热议问题