简体   繁体   English

故事板刷新问题Xcode

[英]storyboard refresh issue Xcode

I have an issue of storyboard refresh all views, when I change constraints it cannot be change in storyboard but change in simulator and device. 我有一个情节提要板刷新所有视图的问题,当我更改约束时,不能在情节提要板上进行更改,而只能在模拟器和设备上进行更改。 But when I reopen my project then it refresh.I tried below step but nothing happened Select storyboard->editor-> refresh all views and also automatically refresh already checked. 但是当我重新打开项目时,它会刷新。我尝试了以下步骤,但没有任何反应选择情节提要->编辑器->刷新所有视图并自动刷新已检查的视图。 Is this bug of Xcode 9.3? 这是Xcode 9.3的错误吗?

Here I attach image:- 我在这里附上图片:- 在此处输入图片说明

but in simulator look like perfect below image:- 但是在模拟器中,下面的图片看起来很完美:-

在此处输入图片说明

Thanks you. 谢谢。

I have also gone through this strange issue. 我也经历了这个奇怪的问题。 I believe it creates if your project becomes so much heavy and lot of storyboards used. 我相信,如果您的项目变得如此繁重并且使用了许多情节提要,它就会创建。 Therefore using Xib instead of Storyboard is the good option. 因此,使用Xib代替Storyboard是一个不错的选择。

If you restart xcode and reopen your project then you can see your view as expected with updated constraint. 如果重新启动xcode并重新打开项目,则可以在更新约束的情况下按预期看到视图。

I got the answer it's happened due to IBDesignable in my custom library class.If I remove all IBDesignable it's work fine. 我得到了答案,这是由于自定义库类中的IBDesignable导致的。如果我删除了所有IBDesignable,则可以正常工作。

Thank you. 谢谢。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM