UIColor Swift gives a different Color

前端 未结 2 560
臣服心动
臣服心动 2021-01-16 06:04

I\'m trying to use this Color

share.backgroundColor = UIColor(red: 53, green: 155, blue: 220, alpha: 0.5)

Which it supposed to be a light blue \

2条回答
  •  再見小時候
    2021-01-16 06:22

    I just did this on some test view controller and I've got the light blue color as expected (Xcode 7 beta 3):

    self.view.backgroundColor = UIColor(red: 53/255.0, green: 155/255.0, blue: 220/255.0, alpha: 0.5)
    

    enter image description here

提交回复
热议问题