You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Since this view is using `UICollectionView` internally you have to provide data same way as you would do with collection view (using dataSource). You can also use delegate if you want to handle item selection or underlaying UIScrollView callbacks. See example project for details.
25
+
26
+
Set the direction to vertical.
27
+
```swift
28
+
pickerView.isHorizontal=false
29
+
```
30
+
31
+
Disable wheel effect of the picker.
32
+
```swift
33
+
pickerView.isFlat=true
34
+
```
35
+
36
+
Prevent center selection when scrolling.
37
+
```swift
38
+
pickerView.selectCenter=false
39
+
```
40
+
41
+
Set spacing between cells, default 10.
42
+
```swift
43
+
pickerView.cellSpacing=10
44
+
```
45
+
46
+
Set cell size (width for horizontal, height for vertical style), default 100.
47
+
```swift
48
+
pickerView.cellSize=100
49
+
```
50
+
51
+
Set wheel effect perspective representation.
52
+
```swift
53
+
pickerView.viewDepth=2000
54
+
```
55
+
56
+
Disable fading gradient mask.
57
+
```swift
58
+
pickerView.maskDisabled=true
59
+
```
60
+
61
+
Current selected index might be obtained from `selectedIndex`.
62
+
```swift
63
+
NSLog("\(pickerView.selectedIndex)")
64
+
```
65
+
66
+
And reload the picker view when any change in data set occurs.
67
+
```swift
68
+
pickerView.reloadData()
69
+
```
70
+
71
+
72
+
22
73
## Example
23
74
24
-
To run the example project, clone the repo, and run `pod install` from the Example directory first.
75
+
To run the example project, clone the repo, and run `pod install` from the Example directory first. Or simplest way is just to run `pod try`.
0 commit comments