我之前使用的是iOS 6.1,但现在我已移至iOS7。随着其他问题的出现,我发现在导航栏中,左栏按钮项的左侧空间和右按钮栏项的右侧空白空间相当大。 IOS 7中的内容比iOS 6中的更多。
我需要知道有什么方法可以减少导航栏中的左右栏按钮项目的空白吗?
提前致谢。
我也面临这个问题。我也有感觉,在iOS 7中有更多的空间。我发现这大约多了10点。当我想LeftBarItemButton
从边缘开始时,我通常使用负空格。这对您也可能有用。
UIBarButtonItem *negativeSpacer = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemFixedSpace target:nil action:nil];
negativeSpacer.width = -16; // it was -6 in iOS 6
[self.navigationItem setLeftBarButtonItems:@[negativeSpacer, requiredButton]; /* this will be the button which you actually need */] animated:NO];
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句