I have multi-image I add to bar item image but when I add it shows very big and I can't shrink them I don't know and I have costume back button but when I add it it shows far from the top left I use this code to add custom back but I add the bar item from storyboard if anyone can help.
let backImg: UIImage = UIImage(named: "back-btn")!
let newBackButton = UIBarButtonItem(image: backImg, style: .plain, target: self, action: #selector(QuestionViewController.back(sender:)))
self.navigationItem.leftBarButtonItem = newBackButton
For navigation set icons in image assets (Assets.xcassets) 1X = 28x28 pixel, 2X = 56x56 pixel and 3X = 84x84 pixel icon size.
https://developer.apple.com/design/human-interface-guidelines/ios/icons-and-images/custom-icons/
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.