How to properly set elevation value to recyclerview?

后端 未结 4 1490
悲哀的现实
悲哀的现实 2021-01-01 18:41

I am working on grid layout using recyclerview in android. The grid occupies a portion of the screen and has a shadow. To get the desired shadow effect I am using an elevati

4条回答
  •  天命终不由人
    2021-01-01 19:11

    Just set below three property in your recyclerview

    android:outlineProvider="bounds"
    android:background="@null"
    android:elevation="2dp"
    

提交回复
热议问题