I was having trouble changing font size in my project, so I made a playground. No matter where I put the font.withSize property, the simulator does not reflect the font size change.
import UIKit
import PlaygroundSupport
class MyViewController : UIViewController {
override func loadView() {
let view = UIView()
view.backgroundColor = .white
let label = UILabel()
label.font.withSize(80)
label.frame = CGRect(x: 150, y: 200, width: 200, height: 20)
label.text = "Hello Mom!"
label.textColor = .black
view.addSubview(label)
self.view = view
}
}