Skip to content

Commit 20f0d4f

Browse files
📝 update documentation to include more methods
1 parent 1cf08c5 commit 20f0d4f

File tree

2 files changed

+16
-9
lines changed

2 files changed

+16
-9
lines changed

DOCUMENTATION.md

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -75,14 +75,16 @@ trianglifyView.setGridWidth(trianglifyView.getWidth())
7575
| Draw strokes | false | .setDrawStrokes(...) | draw_strokes | Draws triangle's border with neighboring triangle's color |
7676
| Color Palette | YlGn | .setPalette(...) | palette | Set of existing colors to color triangles |
7777
| Random Coloring | false | .setRandomColoring(...) | random_coloring | If random coloring is on triangles will be colored randomly instead of linear interpolation |
78-
| Fill the View Completely | false | .setFillViewCompletely(...) | fillViewCompletely| If fillViewCompletely is true, then it will throw illegalArgumentsException whenever both `BleedX` and `BleedY` are not greater than `cellSize`. Refer to [Section 2.2](#2.2)
78+
| Fill the View Completely | false | .setFillViewCompletely(...) | fillViewCompletely| If fillViewCompletely is true, then it will throw illegalArgumentsException whenever both `BleedX` and `BleedY` are not greater than `cellSize`. Refer to [Section 2.2](#22-details-of-bleed-and-grid-dimensions)
7979

8080
*Current release contains only one GridType accessible with id `0`
8181

8282
**Other methods**
83-
These methods are getters for corresponding properties and are not covered in the table above:
83+
The following methods are getters for corresponding properties and are not covered in the table above:
8484
* isDrawStrokeEnabled
8585
* isRandomColoringEnabled
86+
* isFillTriangle
87+
* isFillViewCompletely
8688
* getVariance
8789
* getTypeGrid
8890
* getPalette
@@ -91,11 +93,16 @@ These methods are getters for corresponding properties and are not covered in th
9193
* getCellSize
9294
* getBleedX
9395
* getBleedY
94-
* isFillTriangle
95-
* isFillViewCompletely
96-
* getViewState
97-
* setViewState
98-
For more information on states of view read **Smart update of view using smartUpdate** in [Section 2.7 Updating the View](#27-updating-the-view)
96+
97+
The following are additional methods provided for the developer:
98+
99+
**`getViewState`**
100+
101+
This method returns the state of the view. For more information on states of view read **Smart update of view using smartUpdate** in [Section 2.7 Updating the View](#27-updating-the-view).
102+
103+
**`clearView`**
104+
105+
This method clears the triangulation of the view and sets it to `null`.
99106

100107
#### 2.1.2 Palette
101108
| Method | Return Type | Type | Parameters | Description |

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020

2121
Trianglify is an Android library that helps creates views with beautiful patterns. Trianglify is based on MVP architecture and licensed under MIT license.
2222

23-
# Usages
23+
# How to Apply
2424

2525
Include following line in the gradle script of your application to include latest release of Trianglify:
2626
```gradle
@@ -32,7 +32,7 @@ compile 'com.sdsmdg.kd:trianglify:0.9-beta'
3232
| [demo apk](https://drive.google.com/open?id=0Bz_2jvdEtUlrWEpxQ2Y2RnJGc1U)
3333
* Added custom palette demonstration to demo app
3434
* Added method `fillViewCompletely` to check if view is incompletely filled
35-
* Fixes many bugs [#23](https://github.com/sdsmdg/trianglify/issues/23) [#33](https://github.com/sdsmdg/trianglify/issues/33) [#34](https://github.com/sdsmdg/trianglify/issues/34) [#35](https://github.com/sdsmdg/trianglify/issues/35) [#36](https://github.com/sdsmdg/trianglify/issues/36)
35+
* Fixes many bugs - [#23](https://github.com/sdsmdg/trianglify/issues/23), [#33](https://github.com/sdsmdg/trianglify/issues/33), [#34](https://github.com/sdsmdg/trianglify/issues/34), [#35](https://github.com/sdsmdg/trianglify/issues/35) & [#36](https://github.com/sdsmdg/trianglify/issues/36)
3636

3737
For more check complete [change log](/CHANGELOG.md).
3838

0 commit comments

Comments
 (0)