简体   繁体   English

调整基本视图尺寸iOS

[英]adjust base view size ios

I am trying to create an app with a friend picker, similar to that in Facebook, and other similar apps ( using ECSlidingViewConroller ). 我正在尝试使用类似于Facebook中的朋友选择器的应用程序以及其他类似应用程序( 使用ECSlidingViewConroller )创建一个应用程序。 I have the slider working so far, however because it is sliding to the left, revealing a view below it, on the right, some text is being covered up. 到目前为止,我一直在使用滑块,但是因为它向左滑动,在其下方显示了一个视图,在右边,一些文本被遮盖了。

I'm not sure what the best way to handle this situation is, but my gut feeling was to try to resize the entire view, so that I wouldn't have to resize other things, like if I wanted to add a nav controller, etc. 我不确定解决这种情况的最佳方法是什么,但是我的直觉是尝试调整整个视图的大小,这样我就不必重新调整其他内容的大小,例如如果我想添加导航控制器,等等

在此处输入图片说明

You can see some names on the left that are being covered. 您可以在左侧看到一些被掩盖的名称。 I tried resizing the views frame like this 我试图像这样调整视图框架的大小

[self.view setFrame:CGRectMake(40, 0, self.view.frame.size.width, self.view.frame.size.height)];

also the window 也是窗户

[self.view.window setFrame:CGRectMake(40, 0, self.view.frame.size.width, self.view.frame.size.height)];

Neither of which changed anything. 两者都没有改变。 What are my options here? 我在这里有什么选择?

self.slidingViewController.underRightWidthLayout = ECFixedRevealWidth

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

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