Skip to content

#443 Add zooming to SVG viewer/visualizer

This merge request implements:

  1. Zooming of the SVG document by Ctrl+- and Ctrl+=.
  2. Panning of the SVG document by dragging the document using the mouse.
  3. Resizing of the canvas by resizing the parent window.

I added de demo video to show wat it looks like (see demo.mp4), demo-zoom.mp4.

I am however having one issue. Because images are painted in memory and then passed via a queue there exists a short moment during resize in which the preprinted image does not match de size of the resized canvas. To handle this situation this implementation does not paint the image during resizing. The resulting behavior can be seen in the video issue.mp4, missing-frames.

This behavior is also enabled in the Chi Visualizer als wel as the SVG viewer.

Closes #443

Edited by Dennis Hendriks

Merge request reports