Skip to content

IMR707/photo_view

 
 

Repository files navigation

photo_view Build Status - Travis

A simple zoomable image widget for Flutter projects

PhotoView is useful in full screen exibition cases.

Resolves a image provider and show the result with useful gestures support, such as pinch to zoom and pan.

Todo:

  • Scale on doubleTap
  • Zoom when pinched
  • Respect screen and image boundaries
  • Multiple image support
  • Rotate gesture rotates image

Pull requests are welcome 😊.

Sample code

Given a ImageProvider imageProvider (such as AssetImage or NetworkImage):

@override
Widget build(BuildContext context) {
  return new Container(
    child: new PhotoView(
      imageProvider: imageProvider
    );
  );
}

In action

Constructor

PhotoView({ ImageProvider imageProvider, Widget loadingChild })

Creates a widget that resolves and shows a image with zoom and pan gestures support. If provided, the widget shows loadingChild while the image is being resolved.

About

A simple zoomable image widget for Flutter

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Dart 93.3%
  • Objective-C 4.5%
  • Java 2.2%