UIView with rounded corners and drop shadow?

前端 未结 30 2971
一整个雨季
一整个雨季 2020-11-22 08:00

I’ve been working on an application for a couple of years and received a simple design request: Round the corners on a UIView and add a drop shadow.To do as given below.

30条回答
  •  孤独总比滥情好
    2020-11-22 08:13

    Here is the solution for masksToBounds conflict problem, it works for me.

    After you set the corderRadius/borderColor/shadow and so on, set masksToBounds as NO:

    v.layer.masksToBounds = NO;
    

提交回复
热议问题