I want to programmatically render a UIImage
and then display it on Apple Watch in a WKInterfaceImage
, which height and width I set to "Relative to Container" (so that it basically takes up the entire screen space).
How can I obtain the WKInterfaceImage
's width and and height? As far as I can see, there is no frame
-, border
- oder layer
-property I can access from my extension's code. So what is the proper way to get this information?
Weird enough I have found out that there is a setWidth and setHeight method, but I can't find according getter methods.
At the end of the day I am basically looking for the Watch Kit equivalent to this:
@IBOutlet weak var imageView: UIImageView!
//...
var width = imageView.frame.width
var height = imageView.frame.height