Skip to content

Enable syntax highlighting for code snippets. #62

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Enable syntax highlighting for code snippets.
  • Loading branch information
johnjohndoe committed Aug 18, 2014
commit b342f2d8f0320bd170c14edc71b5b85846000ae4
33 changes: 20 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,16 @@ This is an implementation of the ImageView widget used in the Gallery app of the
Checkout the repository and run the **ImageViewTouchTest** project to see how it works.
Beside the superclass **setImageBitmap** method it offers the following methods:

* `setImageBitmap( final Bitmap bitmap, Matrix matrix );`
* `setImageBitmap( final Bitmap bitmap, Matrix matrix, float minZoom, float maxZoom );`
* `setImageBitmap(final Bitmap bitmap, Matrix matrix);`
* `setImageBitmap(final Bitmap bitmap, Matrix matrix, float minZoom, float maxZoom);`


If you want to load a new Bitmap with a particular zoom/pan state (let's say the same from another ImageView ), you can call:

Matrix matrix = mImageView1.getDisplayMatrix();
mImageView2.setImageBitmap( bitmap, matrix );
```java
Matrix matrix = mImageView1.getDisplayMatrix();
mImageView2.setImageBitmap(bitmap, matrix);
```


## Tweaks
Expand All @@ -25,21 +27,26 @@ The initial display state can be set, using `public void setDisplayType( Display
* `DisplayType.FIT_TO_SCREEN`: The image loaded will always fit the current view's bounds.
* `DisplayType.NONE`: The image will be presented with its current dimensions if smaller than the image bounds, otherwise it will be scaled to fit its contents inside the screen.

The default display state is `DisplayState.NONE'.
The default display state is `DisplayState.NONE`.


##Usage (Maven)
<dependency>
<groupId>it.sephiroth.android.library.imagezoom</groupId>
<artifactId>imagezoom</artifactId>
<version>1.0.5</version>
</dependency>

```xml
<dependency>
<groupId>it.sephiroth.android.library.imagezoom</groupId>
<artifactId>imagezoom</artifactId>
<version>1.0.5</version>
</dependency>
```

##Usage (Gradle)

dependencies {
compile 'it.sephiroth.android.library.imagezoom:imagezoom:+'
}
```groovy
dependencies {
compile 'it.sephiroth.android.library.imagezoom:imagezoom:+'
}
```

##LICENSE

Expand Down