【发布时间】:2018-09-14 10:41:20
【问题描述】:
我正在使用自定义表格视图单元格来创建应用程序,但我需要设置其上边距,因此我可以重复单元格(通过使用 for)并设置顶部。 https://i.imgur.com/ocRtEfg.png
但是,我不知道如何设置它,我尝试使用 topAnchor,但它需要 NSLayoutYAxisAnchor 而我没有。
提前谢谢你!
【问题讨论】:
-
设置顶部插图
-
AutoLayout 是您使用 Nib 时的朋友 - developer.apple.com/library/archive/documentation/…
标签: swift xcode uitableview tableview