mozilla / seasponge

:pineapple: SeaSponge is an accessible threat modelling tool from Mozilla
http://mozilla.github.io/seasponge/
Mozilla Public License 2.0
278 stars 64 forks source link

Implement zooming of drawing area #34

Open Frozenfire92 opened 9 years ago

Frozenfire92 commented 9 years ago

jsPlumb supports this, seems relatively easy

https://jsplumbtoolkit.com/doc/zooming.html

Glavin001 commented 9 years ago

Note that:

Note regarding the drawEndpoints option on jsPlumb.connect: with the default behaviour, jsPlumb uses the offsetParent of the source endpoint in a connection to make final adjustments to the position of a connector. When drawEndpoints is set to false, there is no offsetParent of the source endpoint because it is not visible. If your connection lies inside some container other than the document body, the connector will not be able to take that container's offset into account, and will most likely not be in the right place. You should either use the Blank endpoint when you don't want to see one, or instruct jsPlumb to attach everything to the document body (see below).

From https://jsplumbtoolkit.com/doc/setup


Zooming API: http://www.jsplumb.org/doc/zooming.html

Glavin001 commented 9 years ago

The zoom buttons work, however there should be some research done into jsPlumb such that zooming does not have unexpected visual results, such as cropping the drawing panel. While it is implemented and "works", because of visual bugs I am not closing this issue.