let image :UIImage! = UIImage(named:"connectable_device_ble_pebble")view.backgroundColor = UIColor(patternImage: image)
效果如下:
let image :UIImage! = UIImage(named:"connectable_device_ble_pebble")view.backgroundColor = UIColor(patternImage: image)
效果如下: