Set custom font for UITableView swipe action (UIContextualAction)
问题 How do you set a custom font for the title in UIContextualAction ? I have tried UIAppearance but without any luck... Cheers! :) 回答1: I have found a way to do this by using the image property instead of the title... Standard font (Remove/Rename) Custom font (Remove/Rename) To create an image of a label I have this extension: extension UIImage { /// This method creates an image of a view convenience init?(view: UIView) { // Based on https://stackoverflow.com/a/41288197/1118398 let renderer =