Last time (xcode 9.4) revealed a few incomprehensible bugs to me. 1-the text in the back Bar Button button is not deleted, 2- the shadow for the button created by the program is not added, when launched on the simulator and device there is no shadow. Has anyone encountered this or not?
text removal
override func viewDidLoad() { super.viewDidLoad() navigationItem.backBarButtonItem = UIBarButtonItem(title: "", style: .plain, target: nil, action: nil) } shadow for the button in viewDidLoad
var button = UIButton() override func viewDidLoad() { super.viewDidLoad() button.frame = CGRect(x: 150, y: 200, width: 80, height: 80) button.setTitle("+", for: .normal) button.setTitleColor(UIColor.white, for: .normal) button.backgroundColor = UIColor(red: 245/255, green: 105/255, blue: 144/255, alpha: 1.0) button.titleLabel!.font = UIFont(name:"Gill Sans", size: 23) button.layer.shadowColor = UIColor.black.cgColor button.layer.shadowOffset = CGSize(width: 5, height: 5) button.layer.shadowRadius = 5 button.layer.shadowOpacity = 1.0 button.layer.cornerRadius = 0.5 * button.bounds.size.height button.clipsToBounds = true button.addTarget(self, action: #selector(addList), for:.touchUpInside) self.view.addSubview(button) } 
