Skip to content Skip to sidebar Skip to footer

How To Fit Image In Full Screen In Imageviewtouch

I am using [ImageViewTouch][1] library to zoom a image instead of imageview.

Solution 1:

In it.sephirot.android.library.imagezoom.ImageViewTouchBase change the line

protectedDisplayTypemScaleType= DisplayType.FIT_IF_BIGGER;

in

protectedDisplayTypemScaleType= DisplayType.FIT_TO_SCREEN;

Solution 2:

I had the same issue. After trying a few workarounds without success, finally solved it switching to this library: https://github.com/MikeOrtiz/TouchImageView

Solution 3:

Taken from the example app:

<it.sephiroth.android.library.imagezoom.ImageViewTouch
        android:id="@+id/image"
        android:layout_width="match_parent"
        android:layout_height="0dp"
        android:layout_weight="1"
        android:scaleType="fitCenter" />

Solution 4:

<it.sephiroth.android.library.imagezoom.ImageViewTouch
    android:id="@+id/image"
    android:layout_width="match_parent"
    android:layout_height="0dp"
    android:layout_weight="1"
    android:scaleType="fitXY" />

I think fitXY is fit with the xy coordinate

Solution 5:

Try to call function setDisplayType(DisplayType.FIT_TO_SCREEN) for your imageView

Post a Comment for "How To Fit Image In Full Screen In Imageviewtouch"