ipad 旋转隐藏视图中的元素!
好的,这是一个非常基本的 iPad 应用程序,我刚开始使用它,但我已经遇到了问题。我一直在做iPhone应用程序,但也从未实现过旋转的事情..这就是问题所在。这是一个简单的基于视图的应用程序构建,其界面生成器如下所示:
当我运行应用程序时,垂直方向具有如下两个元素:
但是,当方向更改为水平时,应用程序会隐藏位于顶部.. :
请提出建议!
OK here is a very basic iPad app that i am starting out with and I am already into issue. I have been doing iphone apps but in that too never implemented rotation things.. well here is the issue. This is a simple viewbased app build with interface builder that looks like this:
when i run the app, the vertical orientation has both elements like this :
However, when the orientation changes to horizontal, the app hides the label which is at the top.. :
Suggestions please !
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在 Interface Builder 中,选择标签,然后打开尺寸检查器,并在“自动调整大小”部分中使标签粘贴到窗口的上边缘。您可能还需要将其粘贴到左侧和/或右侧边缘并使其更改宽度 - 取决于您希望在方向更改时如何调整其大小。
In Interface Builder, select the label, then open the size inspector and in Autosizing section make the label stick to the upper edge of the window. You may also need to stick it to the left and/or right edge and make it change the width - depending on how you want it to be resized when orientation changes.