<commit_before># ASJCollectionViewFillLayout

The standard available `UICollectionViewLayout` does the job well, but the UI may look asymmetric, depending on the number of items the `UICollectionView` is displaying. This library attempts to solve this problem. This is a `UICollectionViewLayout` subclass that fills the full width of the collection view.

# Installation

CocoaPods is the preferred way to install this library. Add this command to your `Podfile`:

```
pod 'ASJCollectionViewFillLayout'
```

If you prefer the classic way, just copy the `ASJCollectionViewFillLayout` folder (.h and .m files) to your project.

# Usage

Creating an `ASJCollectionViewFillLayout` is easy. It has a simple interface consisting of three properties. You can also use the traditional delegate pattern to return the attributes you wish to use. All are optional.

```
@property (assign, nonatomic) NSInteger numberOfItemsInRow;
```
Sets the number of items to show in one row.

```
@property (assign, nonatomic) CGFloat itemHeight;
```
Sets the height of an item. The width will be calculated to fill the view.

```
@property (assign, nonatomic) CGFloat itemSpacing;
```
Sets the distance between two collection view items.

![alt tag](Images/7.png)
![alt tag](Images/8.png)

# Credits

- [Implementing UICollectionViewLayout](http://damir.me/implementing-uicollectionview-layout).

# To-do

- ~~Handle case of total collection view items being less than the number of items in one row~~

# License

`ASJCollectionViewFillLayout` is available under the MIT license. See the LICENSE file for more info.
<commit_msg>added article author name<commit_after># ASJCollectionViewFillLayout

The standard available `UICollectionViewLayout` does the job well, but the UI may look asymmetric, depending on the number of items the `UICollectionView` is displaying. This library attempts to solve this problem. This is a `UICollectionViewLayout` subclass that fills the full width of the collection view.

# Installation

CocoaPods is the preferred way to install this library. Add this command to your `Podfile`:

```
pod 'ASJCollectionViewFillLayout'
```

If you prefer the classic way, just copy the `ASJCollectionViewFillLayout` folder (.h and .m files) to your project.

# Usage

Creating an `ASJCollectionViewFillLayout` is easy. It has a simple interface consisting of three properties. You can also use the traditional delegate pattern to return the attributes you wish to use. All are optional.

```
@property (assign, nonatomic) NSInteger numberOfItemsInRow;
```
Sets the number of items to show in one row.

```
@property (assign, nonatomic) CGFloat itemHeight;
```
Sets the height of an item. The width will be calculated to fill the view.

```
@property (assign, nonatomic) CGFloat itemSpacing;
```
Sets the distance between two collection view items.

![alt tag](Images/7.png)
![alt tag](Images/8.png)

# Credits

- To <NAME> - [Implementing UICollectionViewLayout](http://damir.me/implementing-uicollectionview-layout).

# To-do

- ~~Handle case of total collection view items being less than the number of items in one row~~

# License

`ASJCollectionViewFillLayout` is available under the MIT license. See the LICENSE file for more info.

{'fraction_non_alphanumeric': 0.075139146567718, 'fraction_numerical': 0.0012368583797155227, 'mean_word_length': 4.946691176470588, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3154459', 'n_tokens_mistral': 893, 'n_tokens_neox': 874, 'n_words': 415}