My code is very simple; I have an outlet to a UIButton, button
, and I am setting its image in code:
let jack = UIImage(named:"jack.png")
self.button.setImage(jack, for:.normal)
The problem is that this is not behaving as I expect. I expect the button image to be sized down to the button size, and I expect it to be a template image (tinted with the inherited tint color). Instead, I'm seeing the original image and it is full-sized. Is this a change in iOS 15?
It seems to be, because if I set my project's deployment target to iOS 14 and run it on an iOS 14 simulator, I do get the behavior that I expect.