gpt4 book ai didi

uitableview - TableViewController 中的 TabBar 不在底部

转载 作者:行者123 更新时间:2023-11-28 13:21:00 25 4
gpt4 key购买 nike

我正在尝试向我的 TableViewController 添加一个 tabBar,但它不是底部,它就像一个单元格

这是一个截图:

ScreenShot of

最佳答案

当使用 UITableviewController Storyboard场景时,您拖入其中的每个 Tab BarToolbar 都会自动放入 tableView tableFooterView .

如果您不想这样,您必须创建一个 UIViewController 场景。因此,您可以将 Tab BarToolbar 拖到其中,设置其自动布局约束,然后将 UITableView 添加到 UIViewController 场景(见下图)。

enter image description here

不过,还有另一种解决方法。选择您的 Navigation Controller 场景并转到 Attributes Inspector。在模拟指标中,转到底部栏并选择“半透明标签栏”或“半透明工具栏”。然后,选择您的 UITableviewController 场景并重复之前的操作(见下图)。

enter image description here

如果这样做,Navigation Controller 之后的所有 Controller 都会有一个 Tab BarToolbar(这也是另一个问题固定)。

关于uitableview - TableViewController 中的 TabBar 不在底部,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/25774567/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com