B4A Library [B4X] ZoomImageView - Cross platform zoomable + pannable image view

A custom view that shows an image and allows the user to zoom and pan the image.

Instructions:
- Add with designer.
- Call SetBitmap.

Updates:

v1.06 - Fixes an issue with Android 15.
v1.05 - Base_Resize is public. Call it after resizing the view in B4A.
v1.04 - Fixes an issue in B4i where the image jumps when switching from pinch gesture to pan gesture.
v1.03 - Fixes an issue with the click event.
v1.02 - Removed the loading of Picture1.png which was left by mistake.
v1.01 - Fixes an issue with old Android devices.

More sophisticated view that can handle huge images: https://www.b4x.com/android/forum/threads/b4x-hugeimageview-show-very-large-images.132905/#content

1-gif.122485


Tip: simplest way to add ZoomImageView is with SMM: [B4X] SimpleMediaManager (SMM) - framework for images, videos and more
 

Attachments

  • ZoomIVExample.zip
    353.9 KB · Views: 2,198
  • ZoomImageView.b4xlib
    2.7 KB · Views: 139
Last edited:
Top