Programmatically change the height and width of a UIImageView Xcode Swift

前端 未结 7 834
一整个雨季
一整个雨季 2021-02-03 23:00

Hey for some reason I am struggling with trying to set the height and width of one of my image views. I want to set it so the height only goes for 20% of my screen. I know to re

相关标签:
7条回答
  • 2021-02-03 23:46

    Hey i figured it out shortly after. For some reason I was just having a brain fart.

    image.frame = CGRectMake(0 , 0, self.view.frame.width, self.view.frame.height * 0.2)
    
    0 讨论(0)
提交回复
热议问题