skip to Main Content

How to place an ImageView in the center of a UIView? – Ios swift

How to place an ImageView in the center of a UIView? Code: let dailyUIView = UIView(frame: CGRect(x: 0, y: 420, width: view.frame.size.width, height: 40)) dailyUIView.layer.masksToBounds = true dailyUIView.backgroundColor = UIColor(named: "dailyTest") scrollView.addSubview(dailyUIView) let weatherIconImageView = UIImageView(frame: CGRect(x: 70, y: 0,…

VIEW QUESTION
Back To Top
Search