查看未正确填写父级

时间:2015-10-23 01:04:51

标签: ios storyboard autolayout interface-builder

我在视图控制器中有一个UIView,我将背景设置为紫色。

就这么简单

然而它没有正确排队......

enter image description here

在调试视图层次结构中显示剪切的内容'启用它似乎它在左侧调整自己...这似乎是为什么它不匹配到右边缘...

enter idfdsfsd

这实际上只是一个简单的视图。我没有做任何花哨,没有约束等等。它让我疯狂。

enter image description here

修改

好的..事实证明,iPhone 6 plus上的东西很好,问题出在其他iPhone设备尺寸上...... See my other questions where I thought that the 6+ was incorrect...但它实际上是唯一做正确事情的人!

enter image description here

1 个答案:

答案 0 :(得分:0)

在我切换UiView控制器时,这是一个错误......

我改变了

scanf("%f", &(*myArray)[*count].latitude);
scanf("%f", &(*myArray)[*count].longitude);

 self.currentVC.willMoveToParentViewController(nil)
self.addChildViewController(newController)


self.transitionFromViewController(
    self.currentVC!,
    toViewController: newController,
    duration: 0,
    options: UIViewAnimationOptions.CurveEaseIn,
    animations: nil,
    completion: { finished in
        self.currentVC.removeFromParentViewController()
        newController.didMoveToParentViewController(self)
        self.currentVC = newController
})

它解决了我的问题......我还不够先进,不知道是什么导致了它。