Skip to content

Commit

Permalink
Updated README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
shliama committed Jan 21, 2016
1 parent 9da91be commit cf6d0c2
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 4 deletions.
17 changes: 14 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,25 @@

#### This project aims to provide an ultimate and flexible image cropping experience. Made in [Yalantis] (https://yalantis.com/?utm_source=github)

<img src="https://github.com/Yalantis/uCrop/blob/master/preview.png" alt="alt text" style="width:200;height:200">

# Usage

*For a working implementation, please have a look at the Sample Project - sample*

1. Include the library as local library project.

``` compile 'com.yalantis:ucrop:[latest version]' ```
``` compile 'com.yalantis:ucrop:1.0.0' ```

2. Add UCropActivity into your AndroidManifest.xml

2. The uCrop configuration is created using the builder pattern.
```
<activity
android:name="com.yalantis.ucrop.UCropActivity"
android:screenOrientation="portrait"/>
```
3. The uCrop configuration is created using the builder pattern.
```java
UCrop.of(sourceUri, destinationUri)
Expand All @@ -21,7 +30,7 @@
```
3. Override `onActivityResult` method and handle uCrop result.
4. Override `onActivityResult` method and handle uCrop result.
```java
@Override
Expand All @@ -37,6 +46,8 @@
# Customization
If you want to let your users choose crop ratio dynamically, just do not call `withAspectRatio(x, y)`.
uCrop builder class has method `withOptions(UCrop.Options option)` which extends library configurations.
Currently you can change:
Expand Down
3 changes: 3 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ def isReleaseBuild() {
}

allprojects {
version = VERSION_NAME
group = GROUP

repositories {
jcenter()
}
Expand Down
Binary file added preview.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion ucrop/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ android {
minSdkVersion 10
targetSdkVersion 23
versionCode 1
versionName "1.0"
versionName "1.0.0"
}
buildTypes {
release {
Expand Down

0 comments on commit cf6d0c2

Please sign in to comment.