iOS UISearchController width Not equal screen,Right less than screen -
- (uisearchcontroller *)searchcontroller { if (_searchcontroller == nil) { _searchcontroller = [[uisearchcontroller alloc]initwithsearchresultscontroller:nil]; _searchcontroller.searchresultsupdater = self; _searchcontroller.hidesnavigationbarduringpresentation = yes; _searchcontroller.dimsbackgroundduringpresentation = yes; self.tableview.tableheaderview = _searchcontroller.searchbar; } return _searchcontroller; }
don't use uitableviewcontroller, instead use uiviewcontroller subclass. arrange searchbar , tableview. dont put search bar in tableview header.
note: uitableviewcontroller indexed search gives space on right side.
Comments
Post a Comment