| License: |
Open
|
|
Rating: | +19
(31 votes)
|
An grid view for iPhone/iPad, designed to look similar to NSCollectionView. AQGridView is based around the programming model of UITableView and its associated classes.
Similarities with UITableView:
* A subclass of UIScrollView.
* Reusable grid cells, similar to UITableViewCell.
* Data source and delegate very similar to those used with UITableView.
* Immediate and batched changes to the content list (insert, remove, reorder, reload).
* Similar change animations (top, bottom, left, right, fade).
* Simple AQGridViewController provided which performs grid view setup for you, similar to UITableViewController.
* Support for custom header and footer views.
Differences from UITableView:
* No sections— uses NSUInteger as its index location rather than NSIndexPath.
* Data source can specify a desired minimum size for all grid cells.
* Cells are not automatically resized to fit in layout grid— this can be changed via a property.
* The delegate gets an opportunity to adjust the layout frame for each cell as it is displayed.
* The grid layout is adjusted to fit the contentSize width. You can specify left and/or right padding to reach a size which can be divided into three, five, etc. cells per row.
* A customizable ‘glow’ selection style, which places a glow around a cell’s layer (or a specified sublayer) using the shadowRadius property of CALayer. Note that this is only available in iPhone OS 3.2 or later.