How to remove black edge on UIImageView with rounded corners and a border width?
I have the following code to make the UIImageView in each of my UITableView's cells have rounded corners: - (void)awakeFromNib { // Rounded corners. [[cellImage layer] setCornerRadius:([cellImage frame].size.height / 2)]; [[cellImage layer] setMasksToBounds:YES]; [[cellImage layer] setBorderColor:[[UIColor whiteColor] CGColor]]; [[cellImage layer] setBorderWidth:3]; // Trouble! } I want the images to have a bit of a gap between them, and figured I could make use of the border width to make that happen. Below is an image of what actually happened: It's that faint black border that I want to