iOS 7 - 带有搜索功能的 UITableViewController 在状态栏下

标签 ios uitableview uisearchdisplaycontroller ios7

我有一个带有嵌入式 UISearchDisplayController 的 UITableViewController。在 iOS 7 中,搜索框位于状态栏下方。 interface builder 是否有办法偏移 tableview,以便搜索栏不被状态栏覆盖(并且仍然使用 UITableViewController 和 UISearchDisplayController 设置)?

最佳答案

self.edgesForExtendedLayout=UIRectEdgeNone;

应该可以解决这个问题。

关于iOS 7 - 带有搜索功能的 UITableViewController 在状态栏下,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18746718/

相关文章:

ios - 在给定每个子字符串的范围的情况下,从 Objective-C 中的字符串中删除多个子字符串

iphone - 类型名称未知Iphone错误

ios - 如何存储字典[String :[Object]]?

ios - UITableView 继续查看 Controller 不工作

ios - UITableViewAutomaticDimension 打破约束?

ios - 重新加载 searchResultsTableView 时自定义单元格错误

objective-c - 当其他 View Controller 被推送时隐藏 uisearchdisplaycontroller 的导航栏

iphone - SearchDisplay Controller 没有显示我的搜索结果

iphone - 有什么办法可以远程流式传输iOS设备的屏幕?

iOS 11 模拟器在 safari 中无法打开 facebook 登录 - Cordova Facebook4