iOS White to Transparent Gradient Layer is Gray

前端 未结 7 1209
清歌不尽
清歌不尽 2021-02-01 11:53

I have a CAGradientLayer inserted to the bottom of this small detail view that pops up at the bottom of the app. As you can see, I\'ve set the colors from white to clear, but th

相关标签:
7条回答
  • 2021-02-01 12:27

    clearColor has a black color channel with an alpha of 0, so I had to use

    [UIColor colorWithWhite:1 alpha:0]
    

    and it works fine.

    0 讨论(0)
提交回复
热议问题