Search string break when searching

I don't know why, but I get a break between the search bar and the results, as if the area buttons were showing, only they are not.

In the image, the highlighted view is UISearchBarContainerView and the border view is UITableViewWrapperView

Image: http://blog.minetheapp.com/wp-content/uploads/searchgap.jpg

Here's the code to create the search bar:

// set up results controller
let resultsController = SearchResultsController()
searchController = UISearchController(searchResultsController: resultsController)

// set up search bar in article table
let searchBar = searchController.searchBar
searchBar.placeholder = "Procurar Artigo"
searchBar.sizeToFit()

articleTable.tableHeaderView = searchBar
searchController.searchResultsUpdater = resultsController

      

+3
ios8 swift tableview


source to share


No one has answered this question yet

Check out similar questions:

8
UISearchBar overlaps with content of UITableView when active
2
iOS 8 Display search results without search bar
2
Application delay after entering the first character in the search bar
1
Search bar in TableView not working
1
UISearchController view keeps being pushed down when push-popping controllers from searchResultsController
0
Quick search results navigate to a different View controller
0
UINav Bars and Search Bars in iOS 12
0
searchController disappears when clicking on search item
0
Space above first table using UISearchController
0
How do I get rid of the UISearchBar border?



All Articles
Loading...
X
Show
Funny
Dev
Pics