如何从情节提要中删除对象?

How to remove an object from the Storyboard?

UICollectionViewFlowLayout 对象总是带有 UICollectionView

在我的故事板中放置 UICollectionViewControllerUICollectionView 时,我可以看到 UICollectionViewFlowLayout 对象总是伴随着它们。

我没有用。如何删除?

但是,我没有用它,因为我正在处理 UICollectionViewLayout,它略有不同且可自定义。我似乎找不到删除它的方法。也是.

有没有办法删除UICollectionViewFlowLayout对象?

您不能删除 UICollectionViewFlowLayout,因为每个集合视图都需要一个。这只是一个自定义布局或默认布局的问题,但无论哪种方式,它仍在使用布局。

来自 UICollectionView 参考:

A very important object associated with a collection view is the layout object, which is a subclass of the UICollectionViewLayout class. The layout object is responsible for defining the organization and location of all cells and supplementary views inside the collection view.