how can i change the size of a cell
duckjpsgaintas opened this issue · 1 comments
duckjpsgaintas commented
something like
layout.itemSizeOptions.VerticalSize = 200
OR
layout.itemSizeOptions.VerticalSize = YBSlantedCollectionViewLayout(VerticalSize:200, HorizonSize: 200)
always made errors like "YBSlantedCollectionViewLayout has no member VerticalSize" or
"YBSlantedCollectionViewLayoutOptions cannot be constructed because it has no accessible initializers"
so whats the right way to change the size of a cell
thanks a lot !!
yacir commented
Sorry it is an oversight. I released a new version to fix it.
Now with the v 2.1.1
you can set the size options. e.g :
override func viewDidLoad() {
super.viewDidLoad()
let layout = collectionView.collectionViewLayout as! YBSlantedCollectionViewLayout
layout.itemSizeOptions = YBSlantedCollectionViewLayoutSizeOptions(verticalSize: 200, horizontalSize: 200)
}