Skip to content

Commit 707fa9e

Browse files
committed
amended README.md to reflect changes in the constructors
1 parent 123e34f commit 707fa9e

File tree

1 file changed

+33
-6
lines changed

1 file changed

+33
-6
lines changed

README.md

Lines changed: 33 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -49,28 +49,55 @@ Firstly, import NVActivityIndicatorView
4949
import NVActivityIndicatorView
5050
```
5151

52-
Then, there are 4 ways you can do:
52+
Then, there are multiple ways you can create NVActivityIndicatorView:
5353

5454
- Use it in storyboard by changing class of any `UIView` to `NVActivityIndicatorView`
5555
This will use default values 40, white, .Pacman for size, color and type respectively.
5656

57-
- Create with specified type and size 40, color white as default
57+
- Create with specified type, color and size
5858

5959
```swift
60-
NVActivityIndicatorView(frame: frame, type: type)
60+
NVActivityIndicatorView(frame: frame, type: type, color: color, size: size)
6161
```
6262

63-
- Create with specified type, color and size 40 as default
63+
Any of the last three arguments can be omitted. If an argument is omitted it will use the defailt values which are 40, white, .Pacman for size, color and type respectively.
64+
Therefore, you can also create NVActivityIndicatorView using any of the following:
6465

66+
- specify only frame, type and color
6567
```swift
6668
NVActivityIndicatorView(frame: frame, type: type, color: color)
6769
```
6870

69-
- Create with specified type, color, size
71+
- specify only frame, type and size
72+
```swift
73+
NVActivityIndicatorView(frame: frame, type: type, size: size)
74+
```
7075

76+
- specify only frame, size and color
7177
```swift
72-
NVActivityIndicatorView(frame: frame, type: type, color: color, size: size)
78+
NVActivityIndicatorView(frame: frame, size: size, color: color)
7379
```
80+
81+
- specify only frame and type
82+
```swift
83+
NVActivityIndicatorView(frame: frame, type: type)
84+
```
85+
86+
- specify only frame and color
87+
```swift
88+
NVActivityIndicatorView(frame: frame, color: color)
89+
```
90+
91+
- specify only frame and size
92+
```swift
93+
NVActivityIndicatorView(frame: frame, size: size)
94+
```
95+
96+
- specify only frame
97+
```swift
98+
NVActivityIndicatorView(frame: frame)
99+
```
100+
74101
# Acknowledgment
75102

76103
Thanks [Connor Atherton](https://github.com/ConnorAtherton) for great loaders and [Danil Gontovnik](https://github.com/gontovnik) for kick-start.

0 commit comments

Comments
 (0)