How can I replicate UINavigationBar's gradient colors?

后端 未结 4 1880
太阳男子
太阳男子 2021-02-06 13:13

I\'ve been trying to replicate the gradient from UINavigationBar to use as a gradient on custom UIButton subclass objects on the same view.

How

4条回答
  •  不要未来只要你来
    2021-02-06 14:06

    UIButton takes a single tintColor property but that doesn't mean it isn't computing other colors to use in the gradient behind the scenes. Try this tutorial.

提交回复
热议问题