简体   繁体   English

如何为静态表格视图单元格设置自动布局?

[英]how to set autolayout for static table view cell?

I am a beginner, but I usually don't have a problem to set autolayout. 我是一个初学者,但是设置自动版式通常没有问题。 but I am confused when trying to set autolayout for my static table view. 但是当我尝试为我的静态表格视图设置自动布局时,我感到困惑。 here is the screen I want to set 这是我要设置的屏幕

在此处输入图片说明

as we can see below, there is a grey area in the bottom of my static table view, and I want to get rid of it, if the device is bigger, the grey area is also bigger. 如下图所示,我的静态表格视图底部有一个灰色区域,我想摆脱它,如果设备更大,则灰色区域也更大。

在此处输入图片说明

I thought that I can set the table view constraint top bottom left and right to be zero to get rid of that grey area, but I can't set the value of the contraint 我以为可以将表视图约束上下左右设置为零以摆脱该灰色区域,但是我不能设置约束的值

在此处输入图片说明

在此处输入图片说明 so how to get rid of that grey area? 那么如何摆脱灰色地带呢?

Run you app in simulator or actual device you will not see that grey area. 在模拟器或实际设备中运行应用程序,您将看不到该灰色区域。 As you are now seeing in Storyboard preview. 正如您现在在情节提要预览中所看到的。

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

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