How to change zoom in InteractiveViewer with bigger and smaller buttons in Flutter

Viewed 28

I can change the scale with _controller!.value.scale(1 * 1.1);

but the widget zoom starts from the top left corner. How to make it so that the increase would start from the center?

 InteractiveViewer(
        transformationController: _controller,
        child: Image.network(
          'https://klike.net/uploads/posts/2019-05/1556708032_1.jpg',
        ),
      ),


onTap: () {
              setState(() {
                _controller!.value.scale(1 * 1.1);
              });
            }
0 Answers
Related