UISearchBar custom corners
问题 I'm trying to create a search bar like this: But I'm noticing that I'm probably going to have to replace the search bar with my own image because the search bar corners comes out wrong when I set: self.searchController.searchBar.layer.cornerRadius = 50 // I've tried other numbers besides this too with no luck self.searchController.searchBar.clipsToBounds = true If I set this: self.searchController.searchBar.layer.cornerRadius = self.searchController.searchBar.bounds.height/2 The search bar