Platforms to show: All Mac Windows Linux Cross-Platform

Back to NSCollectionViewLayoutAttributesMBS class.

NSCollectionViewLayoutAttributesMBS.ElementKindInterItemGapIndicator as String

Type Topic Plugin Version macOS Windows Linux iOS Targets
shared method Cocoa Collection View MBS MacControls Plugin 21.0 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The element kind string assigned to the attributes object when it represents an inter-item gap.

NSCollectionViewLayoutAttributesMBS.layoutAttributesForDecorationView(decorationViewKind as String, indexPath as NSIndexPathMBS) as NSCollectionViewLayoutAttributesMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
shared method Cocoa Collection View MBS MacControls Plugin 21.0 ✅ Yes ❌ No ❌ No ❌ No Desktop only
Creates and returns a layout attributes object for a decoration view based on the specified information.

decorationViewKind: A string that identifies the type of the decoration view. Use this string to differentiate from among the decoration views in a given section. This parameter must contain a valid value.
indexPath: The index path of the item. You can use this information to identify the item in your app’s data structures.

Returns a new layout attributes object configured with the initial attributes for the decoration view.

Call this method when you need to create a layout attributes object for a decoration view in a collection view. Decoration views are a tertiary type of content that display visual adornments in your collection view interface. For example, decoration views might display custom backgrounds. This method uses the parameters to set the initial values of the indexPath and representedElementKind properties the returned object.

NSCollectionViewLayoutAttributesMBS.layoutAttributesForInterItemGapBefore(indexPath as NSIndexPathMBS) as NSCollectionViewLayoutAttributesMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
shared method Cocoa Collection View MBS MacControls Plugin 21.0 ✅ Yes ❌ No ❌ No ❌ No Desktop only
Creates and returns a layout attributes object for an inter-item gap view at the specified index path.

indexPath: The index path at which to insert the gap view. The gap is placed after the item specified by the index path. This parameter must contain a valid value.

Returns a new layout attributes object configured with the initial attributes for the inter-item gap view.

Call this method when you need to create a layout attributes object for an inter-item gap view in a collection view. Gap views are used during drag and drop to indicate the area where content will drop. This method uses the parameters to set the initial values of the indexPath property of the returned object. The representedElementKind property is set to ElementKindInterItemGapIndicator.

NSCollectionViewLayoutAttributesMBS.layoutAttributesForItem(indexPath as NSIndexPathMBS) as NSCollectionViewLayoutAttributesMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
shared method Cocoa Collection View MBS MacControls Plugin 21.0 ✅ Yes ❌ No ❌ No ❌ No Desktop only
Creates and returns a layout attributes object for the item at the specified index path.

indexPath: The index path of the item. You can use this information to identify the item in your app’s data structures. This parameter must contain a valid value.

Returns a new layout attributes object containing the initial attributes for the item.

Call this method when you need to create a layout attributes object for an item in a collection view. Items are the main type of content presented by a collection view. Items are grouped into sections, although a collection view may have only one section. This method assigns the provided index path to the indexPath property of the returned object.

NSCollectionViewLayoutAttributesMBS.layoutAttributesForSupplementaryView(elementKind as String, indexPath as NSIndexPathMBS) as NSCollectionViewLayoutAttributesMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
shared method Cocoa Collection View MBS MacControls Plugin 21.0 ✅ Yes ❌ No ❌ No ❌ No Desktop only
Creates and returns a layout attributes object for a supplementary view based on the specified information.

elementKind: A string that identifies the type of the supplementary view. Use this string to differentiate from among the supplementary views in a given section. This parameter must contain a valid value.
indexPath: The index path of the item. You can use this information to identify the item in your app’s data structures. This parameter must contain a valid value.

Returns a new layout attributes object configured with the initial attributes for the supplementary view.

Call this method when you need to create a layout attributes object for a supplementary view in a collection view. Supplementary views are a secondary type of content that display data related to a specific section. For example, header and footer views in a grid layout implemented using supplementary views. This method uses the parameters to set the initial values of the indexPath and representedElementKind properties the returned object.

The items on this page are in the following plugins: MBS MacControls Plugin.


The biggest plugin in space...