gpt4 book ai didi

ios - 右侧的“完成”UINavigationBarButtonItem 被截断

转载 作者:塔克拉玛干 更新时间:2023-11-02 08:36:40 24 4
gpt4 key购买 nike

我使用的是 UIBarButtonItem,结果如下:

enter image description here

我正在使用此代码将其添加到导航

 self.doneButton = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemDone target:self action:@selector(dismissWebViewController:)];
[self.navigationItem setRightBarButtonItem:self.doneButton];

我做错了什么?

最佳答案

看起来您的导航栏比屏幕大。将其检查到您的 Storyboard 中。选择导航栏,您必须在元素的开头和结尾看到一个正方形。如果不是,请移动它以适合屏幕。

作为引用,iPhone 6 4.7 英寸应用程序的导航栏宽度为 375。

此外,请检查您是否已正确设置约束。查看您的导航栏的“到最近邻居的间距”,顶部为 0,左右为 -16。

关于ios - 右侧的“完成”UINavigationBarButtonItem 被截断,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29633752/

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