Add gradient to imageview

后端 未结 5 1484
失恋的感觉
失恋的感觉 2020-12-04 16:38

I want to add a gradient on the bottom of my image . Something like this :

\"enter

5条回答
  •  天涯浪人
    2020-12-04 17:15

    Use android:foreground="..." instead of android:background="..."

    Now you won't need to put ImageView and View inside a FrameLayout!

    So your final code will be:

    ImageView

    
    

    Drawable

    
    
        
    
        
    
    

提交回复
热议问题