diff --git a/coverage/coverage-summary.json b/coverage/coverage-summary.json
index 9d5114cee..e9a865f8d 100644
--- a/coverage/coverage-summary.json
+++ b/coverage/coverage-summary.json
@@ -1,71 +1,73 @@
-{"total": {"lines":{"total":6677,"covered":3923,"skipped":0,"pct":58.75},"statements":{"total":6981,"covered":4034,"skipped":0,"pct":57.78},"functions":{"total":1001,"covered":524,"skipped":0,"pct":52.34},"branches":{"total":3421,"covered":1412,"skipped":0,"pct":41.27},"branchesTrue":{"total":0,"covered":0,"skipped":0,"pct":100}}
-,"/Users/jean-francoishenon/Work/svgedit/packages/svgcanvas/common/browser.js": {"lines":{"total":25,"covered":24,"skipped":0,"pct":96},"functions":{"total":6,"covered":2,"skipped":0,"pct":33.33},"statements":{"total":30,"covered":25,"skipped":0,"pct":83.33},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
-,"/Users/jean-francoishenon/Work/svgedit/packages/svgcanvas/common/util.js": {"lines":{"total":90,"covered":8,"skipped":0,"pct":8.88},"functions":{"total":7,"covered":3,"skipped":0,"pct":42.85},"statements":{"total":92,"covered":10,"skipped":0,"pct":10.86},"branches":{"total":98,"covered":10,"skipped":0,"pct":10.2}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/ConfigObj.js": {"lines":{"total":101,"covered":39,"skipped":0,"pct":38.61},"functions":{"total":14,"covered":9,"skipped":0,"pct":64.28},"statements":{"total":102,"covered":39,"skipped":0,"pct":38.23},"branches":{"total":96,"covered":25,"skipped":0,"pct":26.04}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/Editor.js": {"lines":{"total":414,"covered":192,"skipped":0,"pct":46.37},"functions":{"total":103,"covered":31,"skipped":0,"pct":30.09},"statements":{"total":420,"covered":193,"skipped":0,"pct":45.95},"branches":{"total":213,"covered":75,"skipped":0,"pct":35.21}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/EditorStartup.js": {"lines":{"total":383,"covered":237,"skipped":0,"pct":61.87},"functions":{"total":57,"covered":31,"skipped":0,"pct":54.38},"statements":{"total":395,"covered":246,"skipped":0,"pct":62.27},"branches":{"total":147,"covered":51,"skipped":0,"pct":34.69}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/MainMenu.js": {"lines":{"total":101,"covered":44,"skipped":0,"pct":43.56},"functions":{"total":14,"covered":7,"skipped":0,"pct":50},"statements":{"total":101,"covered":44,"skipped":0,"pct":43.56},"branches":{"total":44,"covered":7,"skipped":0,"pct":15.9}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/Rulers.js": {"lines":{"total":119,"covered":93,"skipped":0,"pct":78.15},"functions":{"total":6,"covered":5,"skipped":0,"pct":83.33},"statements":{"total":124,"covered":98,"skipped":0,"pct":79.03},"branches":{"total":43,"covered":32,"skipped":0,"pct":74.41}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/browser-not-supported.js": {"lines":{"total":4,"covered":3,"skipped":0,"pct":75},"functions":{"total":1,"covered":1,"skipped":0,"pct":100},"statements":{"total":4,"covered":3,"skipped":0,"pct":75},"branches":{"total":4,"covered":3,"skipped":0,"pct":75}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/contextmenu.js": {"lines":{"total":22,"covered":9,"skipped":0,"pct":40.9},"functions":{"total":8,"covered":1,"skipped":0,"pct":12.5},"statements":{"total":23,"covered":9,"skipped":0,"pct":39.13},"branches":{"total":13,"covered":0,"skipped":0,"pct":0}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/locale.js": {"lines":{"total":14,"covered":9,"skipped":0,"pct":64.28},"functions":{"total":2,"covered":2,"skipped":0,"pct":100},"statements":{"total":14,"covered":9,"skipped":0,"pct":64.28},"branches":{"total":10,"covered":3,"skipped":0,"pct":30}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/PaintBox.js": {"lines":{"total":64,"covered":51,"skipped":0,"pct":79.68},"functions":{"total":4,"covered":4,"skipped":0,"pct":100},"statements":{"total":67,"covered":53,"skipped":0,"pct":79.1},"branches":{"total":33,"covered":20,"skipped":0,"pct":60.6}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/index.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/seButton.js": {"lines":{"total":57,"covered":41,"skipped":0,"pct":71.92},"functions":{"total":15,"covered":8,"skipped":0,"pct":53.33},"statements":{"total":60,"covered":43,"skipped":0,"pct":71.66},"branches":{"total":33,"covered":23,"skipped":0,"pct":69.69}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/seColorPicker.js": {"lines":{"total":50,"covered":41,"skipped":0,"pct":82},"functions":{"total":16,"covered":11,"skipped":0,"pct":68.75},"statements":{"total":51,"covered":41,"skipped":0,"pct":80.39},"branches":{"total":11,"covered":8,"skipped":0,"pct":72.72}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/seExplorerButton.js": {"lines":{"total":99,"covered":76,"skipped":0,"pct":76.76},"functions":{"total":18,"covered":11,"skipped":0,"pct":61.11},"statements":{"total":102,"covered":76,"skipped":0,"pct":74.5},"branches":{"total":30,"covered":17,"skipped":0,"pct":56.66}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/seFlyingButton.js": {"lines":{"total":77,"covered":50,"skipped":0,"pct":64.93},"functions":{"total":15,"covered":11,"skipped":0,"pct":73.33},"statements":{"total":78,"covered":51,"skipped":0,"pct":65.38},"branches":{"total":31,"covered":13,"skipped":0,"pct":41.93}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/seInput.js": {"lines":{"total":46,"covered":31,"skipped":0,"pct":67.39},"functions":{"total":16,"covered":8,"skipped":0,"pct":50},"statements":{"total":47,"covered":31,"skipped":0,"pct":65.95},"branches":{"total":8,"covered":4,"skipped":0,"pct":50}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/seList.js": {"lines":{"total":87,"covered":59,"skipped":0,"pct":67.81},"functions":{"total":21,"covered":10,"skipped":0,"pct":47.61},"statements":{"total":89,"covered":61,"skipped":0,"pct":68.53},"branches":{"total":22,"covered":12,"skipped":0,"pct":54.54}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/seListItem.js": {"lines":{"total":39,"covered":26,"skipped":0,"pct":66.66},"functions":{"total":12,"covered":4,"skipped":0,"pct":33.33},"statements":{"total":40,"covered":27,"skipped":0,"pct":67.5},"branches":{"total":10,"covered":8,"skipped":0,"pct":80}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/seMenu.js": {"lines":{"total":26,"covered":20,"skipped":0,"pct":76.92},"functions":{"total":7,"covered":3,"skipped":0,"pct":42.85},"statements":{"total":27,"covered":20,"skipped":0,"pct":74.07},"branches":{"total":5,"covered":3,"skipped":0,"pct":60}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/seMenuItem.js": {"lines":{"total":37,"covered":26,"skipped":0,"pct":70.27},"functions":{"total":9,"covered":5,"skipped":0,"pct":55.55},"statements":{"total":40,"covered":27,"skipped":0,"pct":67.5},"branches":{"total":21,"covered":8,"skipped":0,"pct":38.09}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/sePalette.js": {"lines":{"total":53,"covered":44,"skipped":0,"pct":83.01},"functions":{"total":11,"covered":9,"skipped":0,"pct":81.81},"statements":{"total":53,"covered":44,"skipped":0,"pct":83.01},"branches":{"total":15,"covered":10,"skipped":0,"pct":66.66}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/sePlainBorderButton.js": {"lines":{"total":3,"covered":3,"skipped":0,"pct":100},"functions":{"total":1,"covered":1,"skipped":0,"pct":100},"statements":{"total":3,"covered":3,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/sePlainMenuButton.js": {"lines":{"total":2,"covered":2,"skipped":0,"pct":100},"functions":{"total":1,"covered":1,"skipped":0,"pct":100},"statements":{"total":2,"covered":2,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/seSelect.js": {"lines":{"total":56,"covered":45,"skipped":0,"pct":80.35},"functions":{"total":17,"covered":9,"skipped":0,"pct":52.94},"statements":{"total":59,"covered":47,"skipped":0,"pct":79.66},"branches":{"total":16,"covered":14,"skipped":0,"pct":87.5}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/seSpinInput.js": {"lines":{"total":65,"covered":55,"skipped":0,"pct":84.61},"functions":{"total":18,"covered":10,"skipped":0,"pct":55.55},"statements":{"total":66,"covered":55,"skipped":0,"pct":83.33},"branches":{"total":17,"covered":13,"skipped":0,"pct":76.47}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/seText.js": {"lines":{"total":28,"covered":18,"skipped":0,"pct":64.28},"functions":{"total":10,"covered":4,"skipped":0,"pct":40},"statements":{"total":29,"covered":18,"skipped":0,"pct":62.06},"branches":{"total":8,"covered":5,"skipped":0,"pct":62.5}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/seZoom.js": {"lines":{"total":102,"covered":93,"skipped":0,"pct":91.17},"functions":{"total":28,"covered":24,"skipped":0,"pct":85.71},"statements":{"total":107,"covered":97,"skipped":0,"pct":90.65},"branches":{"total":36,"covered":21,"skipped":0,"pct":58.33}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/jgraduate/ColorValuePicker.js": {"lines":{"total":231,"covered":54,"skipped":0,"pct":23.37},"functions":{"total":9,"covered":3,"skipped":0,"pct":33.33},"statements":{"total":249,"covered":63,"skipped":0,"pct":25.3},"branches":{"total":157,"covered":34,"skipped":0,"pct":21.65}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/jgraduate/Slider.js": {"lines":{"total":156,"covered":91,"skipped":0,"pct":58.33},"functions":{"total":17,"covered":9,"skipped":0,"pct":52.94},"statements":{"total":176,"covered":96,"skipped":0,"pct":54.54},"branches":{"total":186,"covered":97,"skipped":0,"pct":52.15}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/jgraduate/jQuery.jGraduate.js": {"lines":{"total":580,"covered":275,"skipped":0,"pct":47.41},"functions":{"total":44,"covered":14,"skipped":0,"pct":31.81},"statements":{"total":602,"covered":282,"skipped":0,"pct":46.84},"branches":{"total":278,"covered":100,"skipped":0,"pct":35.97}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/components/jgraduate/jQuery.jPicker.js": {"lines":{"total":840,"covered":449,"skipped":0,"pct":53.45},"functions":{"total":60,"covered":39,"skipped":0,"pct":65},"statements":{"total":926,"covered":475,"skipped":0,"pct":51.29},"branches":{"total":777,"covered":327,"skipped":0,"pct":42.08}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/dialogs/SePlainAlertDialog.js": {"lines":{"total":12,"covered":2,"skipped":0,"pct":16.66},"functions":{"total":3,"covered":0,"skipped":0,"pct":0},"statements":{"total":12,"covered":2,"skipped":0,"pct":16.66},"branches":{"total":4,"covered":0,"skipped":0,"pct":0}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/dialogs/cmenuDialog.js": {"lines":{"total":120,"covered":112,"skipped":0,"pct":93.33},"functions":{"total":28,"covered":16,"skipped":0,"pct":57.14},"statements":{"total":131,"covered":117,"skipped":0,"pct":89.31},"branches":{"total":23,"covered":19,"skipped":0,"pct":82.6}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/dialogs/cmenuLayersDialog.js": {"lines":{"total":61,"covered":49,"skipped":0,"pct":80.32},"functions":{"total":16,"covered":6,"skipped":0,"pct":37.5},"statements":{"total":66,"covered":49,"skipped":0,"pct":74.24},"branches":{"total":18,"covered":13,"skipped":0,"pct":72.22}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/dialogs/editorPreferencesDialog.js": {"lines":{"total":157,"covered":125,"skipped":0,"pct":79.61},"functions":{"total":30,"covered":9,"skipped":0,"pct":30},"statements":{"total":159,"covered":126,"skipped":0,"pct":79.24},"branches":{"total":46,"covered":35,"skipped":0,"pct":76.08}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/dialogs/exportDialog.js": {"lines":{"total":52,"covered":36,"skipped":0,"pct":69.23},"functions":{"total":14,"covered":5,"skipped":0,"pct":35.71},"statements":{"total":55,"covered":36,"skipped":0,"pct":65.45},"branches":{"total":11,"covered":5,"skipped":0,"pct":45.45}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/dialogs/imagePropertiesDialog.js": {"lines":{"total":161,"covered":90,"skipped":0,"pct":55.9},"functions":{"total":20,"covered":5,"skipped":0,"pct":25},"statements":{"total":162,"covered":90,"skipped":0,"pct":55.55},"branches":{"total":53,"covered":23,"skipped":0,"pct":43.39}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/dialogs/index.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/dialogs/seAlertDialog.js": {"lines":{"total":6,"covered":2,"skipped":0,"pct":33.33},"functions":{"total":1,"covered":0,"skipped":0,"pct":0},"statements":{"total":6,"covered":2,"skipped":0,"pct":33.33},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/dialogs/seConfirmDialog.js": {"lines":{"total":8,"covered":2,"skipped":0,"pct":25},"functions":{"total":1,"covered":0,"skipped":0,"pct":0},"statements":{"total":8,"covered":2,"skipped":0,"pct":25},"branches":{"total":4,"covered":0,"skipped":0,"pct":0}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/dialogs/sePromptDialog.js": {"lines":{"total":24,"covered":5,"skipped":0,"pct":20.83},"functions":{"total":7,"covered":2,"skipped":0,"pct":28.57},"statements":{"total":24,"covered":5,"skipped":0,"pct":20.83},"branches":{"total":9,"covered":0,"skipped":0,"pct":0}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/dialogs/seSelectDialog.js": {"lines":{"total":8,"covered":2,"skipped":0,"pct":25},"functions":{"total":1,"covered":0,"skipped":0,"pct":0},"statements":{"total":8,"covered":2,"skipped":0,"pct":25},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/dialogs/svgSourceDialog.js": {"lines":{"total":74,"covered":56,"skipped":0,"pct":75.67},"functions":{"total":17,"covered":6,"skipped":0,"pct":35.29},"statements":{"total":75,"covered":57,"skipped":0,"pct":76},"branches":{"total":17,"covered":14,"skipped":0,"pct":82.35}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/dialogs/se-elix/define/NumberSpinBox.js": {"lines":{"total":1,"covered":1,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":1,"covered":1,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/dialogs/se-elix/src/base/NumberSpinBox.js": {"lines":{"total":54,"covered":51,"skipped":0,"pct":94.44},"functions":{"total":13,"covered":11,"skipped":0,"pct":84.61},"statements":{"total":54,"covered":51,"skipped":0,"pct":94.44},"branches":{"total":53,"covered":46,"skipped":0,"pct":86.79}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/dialogs/se-elix/src/plain/PlainNumberSpinBox.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/extensions/ext-connector/ext-connector.js": {"lines":{"total":287,"covered":84,"skipped":0,"pct":29.26},"functions":{"total":26,"covered":16,"skipped":0,"pct":61.53},"statements":{"total":295,"covered":87,"skipped":0,"pct":29.49},"branches":{"total":140,"covered":21,"skipped":0,"pct":15}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/extensions/ext-connector/locale/en.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/extensions/ext-eyedropper/ext-eyedropper.js": {"lines":{"total":99,"covered":57,"skipped":0,"pct":57.57},"functions":{"total":16,"covered":11,"skipped":0,"pct":68.75},"statements":{"total":109,"covered":58,"skipped":0,"pct":53.21},"branches":{"total":65,"covered":19,"skipped":0,"pct":29.23}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/extensions/ext-eyedropper/locale/en.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/extensions/ext-grid/ext-grid.js": {"lines":{"total":88,"covered":43,"skipped":0,"pct":48.86},"functions":{"total":8,"covered":4,"skipped":0,"pct":50},"statements":{"total":90,"covered":43,"skipped":0,"pct":47.77},"branches":{"total":10,"covered":4,"skipped":0,"pct":40}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/extensions/ext-grid/locale/en.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/extensions/ext-markers/ext-markers.js": {"lines":{"total":149,"covered":46,"skipped":0,"pct":30.87},"functions":{"total":21,"covered":12,"skipped":0,"pct":57.14},"statements":{"total":164,"covered":48,"skipped":0,"pct":29.26},"branches":{"total":80,"covered":22,"skipped":0,"pct":27.5}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/extensions/ext-opensave/ext-opensave.js": {"lines":{"total":136,"covered":36,"skipped":0,"pct":26.47},"functions":{"total":13,"covered":3,"skipped":0,"pct":23.07},"statements":{"total":141,"covered":36,"skipped":0,"pct":25.53},"branches":{"total":32,"covered":0,"skipped":0,"pct":0}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/extensions/ext-opensave/locale/en.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/extensions/ext-panning/ext-panning.js": {"lines":{"total":30,"covered":22,"skipped":0,"pct":73.33},"functions":{"total":7,"covered":6,"skipped":0,"pct":85.71},"statements":{"total":30,"covered":22,"skipped":0,"pct":73.33},"branches":{"total":6,"covered":2,"skipped":0,"pct":33.33}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/extensions/ext-panning/locale/en.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/extensions/ext-polystar/ext-polystar.js": {"lines":{"total":247,"covered":232,"skipped":0,"pct":93.92},"functions":{"total":18,"covered":16,"skipped":0,"pct":88.88},"statements":{"total":256,"covered":241,"skipped":0,"pct":94.14},"branches":{"total":62,"covered":39,"skipped":0,"pct":62.9}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/extensions/ext-polystar/locale/en.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/extensions/ext-shapes/ext-shapes.js": {"lines":{"total":76,"covered":74,"skipped":0,"pct":97.36},"functions":{"total":7,"covered":7,"skipped":0,"pct":100},"statements":{"total":80,"covered":78,"skipped":0,"pct":97.5},"branches":{"total":26,"covered":17,"skipped":0,"pct":65.38}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/extensions/ext-shapes/locale/en.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/extensions/ext-storage/ext-storage.js": {"lines":{"total":91,"covered":37,"skipped":0,"pct":40.65},"functions":{"total":12,"covered":5,"skipped":0,"pct":41.66},"statements":{"total":91,"covered":37,"skipped":0,"pct":40.65},"branches":{"total":68,"covered":16,"skipped":0,"pct":23.52}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/extensions/ext-storage/storageDialog.js": {"lines":{"total":60,"covered":56,"skipped":0,"pct":93.33},"functions":{"total":10,"covered":7,"skipped":0,"pct":70},"statements":{"total":62,"covered":57,"skipped":0,"pct":91.93},"branches":{"total":15,"covered":13,"skipped":0,"pct":86.66}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/locale/lang.en.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/panels/BottomPanel.js": {"lines":{"total":77,"covered":61,"skipped":0,"pct":79.22},"functions":{"total":22,"covered":14,"skipped":0,"pct":63.63},"statements":{"total":77,"covered":61,"skipped":0,"pct":79.22},"branches":{"total":30,"covered":16,"skipped":0,"pct":53.33}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/panels/LayersPanel.js": {"lines":{"total":162,"covered":75,"skipped":0,"pct":46.29},"functions":{"total":27,"covered":6,"skipped":0,"pct":22.22},"statements":{"total":168,"covered":76,"skipped":0,"pct":45.23},"branches":{"total":46,"covered":6,"skipped":0,"pct":13.04}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/panels/LeftPanel.js": {"lines":{"total":57,"covered":46,"skipped":0,"pct":80.7},"functions":{"total":20,"covered":15,"skipped":0,"pct":75},"statements":{"total":58,"covered":46,"skipped":0,"pct":79.31},"branches":{"total":32,"covered":12,"skipped":0,"pct":37.5}}
-,"/Users/jean-francoishenon/Work/svgedit/src/editor/panels/TopPanel.js": {"lines":{"total":409,"covered":313,"skipped":0,"pct":76.52},"functions":{"total":76,"covered":52,"skipped":0,"pct":68.42},"statements":{"total":421,"covered":316,"skipped":0,"pct":75.05},"branches":{"total":209,"covered":127,"skipped":0,"pct":60.76}}
+{"total": {"lines":{"total":6724,"covered":3944,"skipped":0,"pct":58.65},"statements":{"total":7028,"covered":4055,"skipped":0,"pct":57.69},"functions":{"total":1009,"covered":529,"skipped":0,"pct":52.42},"branches":{"total":3434,"covered":1414,"skipped":0,"pct":41.17},"branchesTrue":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/packages/svgcanvas/common/browser.js": {"lines":{"total":25,"covered":24,"skipped":0,"pct":96},"functions":{"total":6,"covered":2,"skipped":0,"pct":33.33},"statements":{"total":30,"covered":25,"skipped":0,"pct":83.33},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/packages/svgcanvas/common/util.js": {"lines":{"total":90,"covered":8,"skipped":0,"pct":8.88},"functions":{"total":7,"covered":3,"skipped":0,"pct":42.85},"statements":{"total":92,"covered":10,"skipped":0,"pct":10.86},"branches":{"total":98,"covered":10,"skipped":0,"pct":10.2}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/ConfigObj.js": {"lines":{"total":101,"covered":39,"skipped":0,"pct":38.61},"functions":{"total":14,"covered":9,"skipped":0,"pct":64.28},"statements":{"total":102,"covered":39,"skipped":0,"pct":38.23},"branches":{"total":95,"covered":25,"skipped":0,"pct":26.31}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/Editor.js": {"lines":{"total":414,"covered":192,"skipped":0,"pct":46.37},"functions":{"total":103,"covered":31,"skipped":0,"pct":30.09},"statements":{"total":420,"covered":193,"skipped":0,"pct":45.95},"branches":{"total":213,"covered":75,"skipped":0,"pct":35.21}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/EditorStartup.js": {"lines":{"total":383,"covered":237,"skipped":0,"pct":61.87},"functions":{"total":57,"covered":31,"skipped":0,"pct":54.38},"statements":{"total":395,"covered":246,"skipped":0,"pct":62.27},"branches":{"total":147,"covered":51,"skipped":0,"pct":34.69}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/MainMenu.js": {"lines":{"total":101,"covered":44,"skipped":0,"pct":43.56},"functions":{"total":14,"covered":7,"skipped":0,"pct":50},"statements":{"total":101,"covered":44,"skipped":0,"pct":43.56},"branches":{"total":44,"covered":7,"skipped":0,"pct":15.9}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/Rulers.js": {"lines":{"total":119,"covered":93,"skipped":0,"pct":78.15},"functions":{"total":6,"covered":5,"skipped":0,"pct":83.33},"statements":{"total":124,"covered":98,"skipped":0,"pct":79.03},"branches":{"total":43,"covered":32,"skipped":0,"pct":74.41}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/browser-not-supported.js": {"lines":{"total":4,"covered":3,"skipped":0,"pct":75},"functions":{"total":1,"covered":1,"skipped":0,"pct":100},"statements":{"total":4,"covered":3,"skipped":0,"pct":75},"branches":{"total":4,"covered":3,"skipped":0,"pct":75}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/contextmenu.js": {"lines":{"total":22,"covered":9,"skipped":0,"pct":40.9},"functions":{"total":8,"covered":1,"skipped":0,"pct":12.5},"statements":{"total":23,"covered":9,"skipped":0,"pct":39.13},"branches":{"total":13,"covered":0,"skipped":0,"pct":0}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/locale.js": {"lines":{"total":14,"covered":9,"skipped":0,"pct":64.28},"functions":{"total":2,"covered":2,"skipped":0,"pct":100},"statements":{"total":14,"covered":9,"skipped":0,"pct":64.28},"branches":{"total":10,"covered":3,"skipped":0,"pct":30}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/PaintBox.js": {"lines":{"total":64,"covered":51,"skipped":0,"pct":79.68},"functions":{"total":4,"covered":4,"skipped":0,"pct":100},"statements":{"total":67,"covered":53,"skipped":0,"pct":79.1},"branches":{"total":33,"covered":20,"skipped":0,"pct":60.6}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/index.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/seButton.js": {"lines":{"total":57,"covered":42,"skipped":0,"pct":73.68},"functions":{"total":15,"covered":9,"skipped":0,"pct":60},"statements":{"total":60,"covered":44,"skipped":0,"pct":73.33},"branches":{"total":33,"covered":23,"skipped":0,"pct":69.69}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/seColorPicker.js": {"lines":{"total":50,"covered":41,"skipped":0,"pct":82},"functions":{"total":16,"covered":11,"skipped":0,"pct":68.75},"statements":{"total":51,"covered":41,"skipped":0,"pct":80.39},"branches":{"total":11,"covered":8,"skipped":0,"pct":72.72}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/seExplorerButton.js": {"lines":{"total":99,"covered":76,"skipped":0,"pct":76.76},"functions":{"total":18,"covered":11,"skipped":0,"pct":61.11},"statements":{"total":102,"covered":76,"skipped":0,"pct":74.5},"branches":{"total":30,"covered":17,"skipped":0,"pct":56.66}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/seFlyingButton.js": {"lines":{"total":77,"covered":50,"skipped":0,"pct":64.93},"functions":{"total":15,"covered":11,"skipped":0,"pct":73.33},"statements":{"total":78,"covered":51,"skipped":0,"pct":65.38},"branches":{"total":31,"covered":13,"skipped":0,"pct":41.93}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/seInput.js": {"lines":{"total":46,"covered":31,"skipped":0,"pct":67.39},"functions":{"total":16,"covered":8,"skipped":0,"pct":50},"statements":{"total":47,"covered":31,"skipped":0,"pct":65.95},"branches":{"total":8,"covered":4,"skipped":0,"pct":50}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/seList.js": {"lines":{"total":87,"covered":59,"skipped":0,"pct":67.81},"functions":{"total":21,"covered":10,"skipped":0,"pct":47.61},"statements":{"total":89,"covered":61,"skipped":0,"pct":68.53},"branches":{"total":22,"covered":12,"skipped":0,"pct":54.54}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/seListItem.js": {"lines":{"total":39,"covered":26,"skipped":0,"pct":66.66},"functions":{"total":12,"covered":4,"skipped":0,"pct":33.33},"statements":{"total":40,"covered":27,"skipped":0,"pct":67.5},"branches":{"total":10,"covered":8,"skipped":0,"pct":80}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/seMenu.js": {"lines":{"total":26,"covered":20,"skipped":0,"pct":76.92},"functions":{"total":7,"covered":3,"skipped":0,"pct":42.85},"statements":{"total":27,"covered":20,"skipped":0,"pct":74.07},"branches":{"total":5,"covered":3,"skipped":0,"pct":60}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/seMenuItem.js": {"lines":{"total":37,"covered":26,"skipped":0,"pct":70.27},"functions":{"total":9,"covered":5,"skipped":0,"pct":55.55},"statements":{"total":40,"covered":27,"skipped":0,"pct":67.5},"branches":{"total":21,"covered":8,"skipped":0,"pct":38.09}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/sePalette.js": {"lines":{"total":53,"covered":44,"skipped":0,"pct":83.01},"functions":{"total":11,"covered":9,"skipped":0,"pct":81.81},"statements":{"total":53,"covered":44,"skipped":0,"pct":83.01},"branches":{"total":15,"covered":10,"skipped":0,"pct":66.66}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/sePlainBorderButton.js": {"lines":{"total":3,"covered":3,"skipped":0,"pct":100},"functions":{"total":1,"covered":1,"skipped":0,"pct":100},"statements":{"total":3,"covered":3,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/sePlainMenuButton.js": {"lines":{"total":2,"covered":2,"skipped":0,"pct":100},"functions":{"total":1,"covered":1,"skipped":0,"pct":100},"statements":{"total":2,"covered":2,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/seSelect.js": {"lines":{"total":56,"covered":45,"skipped":0,"pct":80.35},"functions":{"total":17,"covered":9,"skipped":0,"pct":52.94},"statements":{"total":59,"covered":47,"skipped":0,"pct":79.66},"branches":{"total":16,"covered":14,"skipped":0,"pct":87.5}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/seSpinInput.js": {"lines":{"total":65,"covered":55,"skipped":0,"pct":84.61},"functions":{"total":18,"covered":10,"skipped":0,"pct":55.55},"statements":{"total":66,"covered":55,"skipped":0,"pct":83.33},"branches":{"total":17,"covered":13,"skipped":0,"pct":76.47}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/seText.js": {"lines":{"total":28,"covered":18,"skipped":0,"pct":64.28},"functions":{"total":10,"covered":4,"skipped":0,"pct":40},"statements":{"total":29,"covered":18,"skipped":0,"pct":62.06},"branches":{"total":8,"covered":5,"skipped":0,"pct":62.5}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/seZoom.js": {"lines":{"total":102,"covered":94,"skipped":0,"pct":92.15},"functions":{"total":28,"covered":25,"skipped":0,"pct":89.28},"statements":{"total":107,"covered":98,"skipped":0,"pct":91.58},"branches":{"total":36,"covered":22,"skipped":0,"pct":61.11}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/jgraduate/ColorValuePicker.js": {"lines":{"total":231,"covered":54,"skipped":0,"pct":23.37},"functions":{"total":9,"covered":3,"skipped":0,"pct":33.33},"statements":{"total":249,"covered":63,"skipped":0,"pct":25.3},"branches":{"total":157,"covered":34,"skipped":0,"pct":21.65}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/jgraduate/Slider.js": {"lines":{"total":156,"covered":91,"skipped":0,"pct":58.33},"functions":{"total":17,"covered":9,"skipped":0,"pct":52.94},"statements":{"total":176,"covered":96,"skipped":0,"pct":54.54},"branches":{"total":186,"covered":97,"skipped":0,"pct":52.15}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/jgraduate/jQuery.jGraduate.js": {"lines":{"total":580,"covered":275,"skipped":0,"pct":47.41},"functions":{"total":44,"covered":14,"skipped":0,"pct":31.81},"statements":{"total":602,"covered":282,"skipped":0,"pct":46.84},"branches":{"total":278,"covered":100,"skipped":0,"pct":35.97}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/components/jgraduate/jQuery.jPicker.js": {"lines":{"total":840,"covered":449,"skipped":0,"pct":53.45},"functions":{"total":60,"covered":39,"skipped":0,"pct":65},"statements":{"total":926,"covered":475,"skipped":0,"pct":51.29},"branches":{"total":777,"covered":327,"skipped":0,"pct":42.08}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/dialogs/SePlainAlertDialog.js": {"lines":{"total":12,"covered":2,"skipped":0,"pct":16.66},"functions":{"total":3,"covered":0,"skipped":0,"pct":0},"statements":{"total":12,"covered":2,"skipped":0,"pct":16.66},"branches":{"total":4,"covered":0,"skipped":0,"pct":0}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/dialogs/cmenuDialog.js": {"lines":{"total":120,"covered":112,"skipped":0,"pct":93.33},"functions":{"total":28,"covered":16,"skipped":0,"pct":57.14},"statements":{"total":131,"covered":117,"skipped":0,"pct":89.31},"branches":{"total":23,"covered":19,"skipped":0,"pct":82.6}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/dialogs/cmenuLayersDialog.js": {"lines":{"total":61,"covered":49,"skipped":0,"pct":80.32},"functions":{"total":16,"covered":6,"skipped":0,"pct":37.5},"statements":{"total":66,"covered":49,"skipped":0,"pct":74.24},"branches":{"total":18,"covered":13,"skipped":0,"pct":72.22}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/dialogs/editorPreferencesDialog.js": {"lines":{"total":157,"covered":125,"skipped":0,"pct":79.61},"functions":{"total":30,"covered":9,"skipped":0,"pct":30},"statements":{"total":159,"covered":126,"skipped":0,"pct":79.24},"branches":{"total":46,"covered":35,"skipped":0,"pct":76.08}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/dialogs/exportDialog.js": {"lines":{"total":52,"covered":36,"skipped":0,"pct":69.23},"functions":{"total":14,"covered":5,"skipped":0,"pct":35.71},"statements":{"total":55,"covered":36,"skipped":0,"pct":65.45},"branches":{"total":11,"covered":5,"skipped":0,"pct":45.45}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/dialogs/imagePropertiesDialog.js": {"lines":{"total":161,"covered":90,"skipped":0,"pct":55.9},"functions":{"total":20,"covered":5,"skipped":0,"pct":25},"statements":{"total":162,"covered":90,"skipped":0,"pct":55.55},"branches":{"total":53,"covered":23,"skipped":0,"pct":43.39}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/dialogs/index.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/dialogs/seAlertDialog.js": {"lines":{"total":6,"covered":2,"skipped":0,"pct":33.33},"functions":{"total":1,"covered":0,"skipped":0,"pct":0},"statements":{"total":6,"covered":2,"skipped":0,"pct":33.33},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/dialogs/seConfirmDialog.js": {"lines":{"total":8,"covered":2,"skipped":0,"pct":25},"functions":{"total":1,"covered":0,"skipped":0,"pct":0},"statements":{"total":8,"covered":2,"skipped":0,"pct":25},"branches":{"total":4,"covered":0,"skipped":0,"pct":0}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/dialogs/sePromptDialog.js": {"lines":{"total":24,"covered":5,"skipped":0,"pct":20.83},"functions":{"total":7,"covered":2,"skipped":0,"pct":28.57},"statements":{"total":24,"covered":5,"skipped":0,"pct":20.83},"branches":{"total":9,"covered":0,"skipped":0,"pct":0}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/dialogs/seSelectDialog.js": {"lines":{"total":8,"covered":2,"skipped":0,"pct":25},"functions":{"total":1,"covered":0,"skipped":0,"pct":0},"statements":{"total":8,"covered":2,"skipped":0,"pct":25},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/dialogs/svgSourceDialog.js": {"lines":{"total":74,"covered":56,"skipped":0,"pct":75.67},"functions":{"total":17,"covered":6,"skipped":0,"pct":35.29},"statements":{"total":75,"covered":57,"skipped":0,"pct":76},"branches":{"total":17,"covered":14,"skipped":0,"pct":82.35}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/dialogs/se-elix/define/NumberSpinBox.js": {"lines":{"total":1,"covered":1,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":1,"covered":1,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/dialogs/se-elix/src/base/NumberSpinBox.js": {"lines":{"total":54,"covered":51,"skipped":0,"pct":94.44},"functions":{"total":13,"covered":11,"skipped":0,"pct":84.61},"statements":{"total":54,"covered":51,"skipped":0,"pct":94.44},"branches":{"total":53,"covered":46,"skipped":0,"pct":86.79}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/dialogs/se-elix/src/plain/PlainNumberSpinBox.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-connector/ext-connector.js": {"lines":{"total":287,"covered":84,"skipped":0,"pct":29.26},"functions":{"total":26,"covered":16,"skipped":0,"pct":61.53},"statements":{"total":295,"covered":87,"skipped":0,"pct":29.49},"branches":{"total":140,"covered":21,"skipped":0,"pct":15}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-connector/locale/en.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-eyedropper/ext-eyedropper.js": {"lines":{"total":99,"covered":57,"skipped":0,"pct":57.57},"functions":{"total":16,"covered":11,"skipped":0,"pct":68.75},"statements":{"total":109,"covered":58,"skipped":0,"pct":53.21},"branches":{"total":65,"covered":19,"skipped":0,"pct":29.23}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-eyedropper/locale/en.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-grid/ext-grid.js": {"lines":{"total":88,"covered":43,"skipped":0,"pct":48.86},"functions":{"total":8,"covered":4,"skipped":0,"pct":50},"statements":{"total":90,"covered":43,"skipped":0,"pct":47.77},"branches":{"total":10,"covered":4,"skipped":0,"pct":40}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-grid/locale/en.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-layer_view/ext-layer_view.js": {"lines":{"total":43,"covered":21,"skipped":0,"pct":48.83},"functions":{"total":8,"covered":4,"skipped":0,"pct":50},"statements":{"total":43,"covered":21,"skipped":0,"pct":48.83},"branches":{"total":14,"covered":2,"skipped":0,"pct":14.28}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-layer_view/locale/en.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-markers/ext-markers.js": {"lines":{"total":149,"covered":46,"skipped":0,"pct":30.87},"functions":{"total":21,"covered":12,"skipped":0,"pct":57.14},"statements":{"total":164,"covered":48,"skipped":0,"pct":29.26},"branches":{"total":80,"covered":22,"skipped":0,"pct":27.5}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-opensave/ext-opensave.js": {"lines":{"total":137,"covered":36,"skipped":0,"pct":26.27},"functions":{"total":13,"covered":3,"skipped":0,"pct":23.07},"statements":{"total":142,"covered":36,"skipped":0,"pct":25.35},"branches":{"total":32,"covered":0,"skipped":0,"pct":0}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-opensave/locale/en.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-panning/ext-panning.js": {"lines":{"total":30,"covered":22,"skipped":0,"pct":73.33},"functions":{"total":7,"covered":6,"skipped":0,"pct":85.71},"statements":{"total":30,"covered":22,"skipped":0,"pct":73.33},"branches":{"total":6,"covered":2,"skipped":0,"pct":33.33}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-panning/locale/en.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-polystar/ext-polystar.js": {"lines":{"total":247,"covered":232,"skipped":0,"pct":93.92},"functions":{"total":18,"covered":16,"skipped":0,"pct":88.88},"statements":{"total":256,"covered":241,"skipped":0,"pct":94.14},"branches":{"total":62,"covered":39,"skipped":0,"pct":62.9}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-polystar/locale/en.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-shapes/ext-shapes.js": {"lines":{"total":76,"covered":74,"skipped":0,"pct":97.36},"functions":{"total":7,"covered":7,"skipped":0,"pct":100},"statements":{"total":80,"covered":78,"skipped":0,"pct":97.5},"branches":{"total":26,"covered":17,"skipped":0,"pct":65.38}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-shapes/locale/en.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-storage/ext-storage.js": {"lines":{"total":91,"covered":37,"skipped":0,"pct":40.65},"functions":{"total":12,"covered":5,"skipped":0,"pct":41.66},"statements":{"total":91,"covered":37,"skipped":0,"pct":40.65},"branches":{"total":68,"covered":16,"skipped":0,"pct":23.52}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/extensions/ext-storage/storageDialog.js": {"lines":{"total":60,"covered":56,"skipped":0,"pct":93.33},"functions":{"total":10,"covered":7,"skipped":0,"pct":70},"statements":{"total":62,"covered":57,"skipped":0,"pct":91.93},"branches":{"total":15,"covered":13,"skipped":0,"pct":86.66}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/locale/lang.en.js": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/panels/BottomPanel.js": {"lines":{"total":77,"covered":61,"skipped":0,"pct":79.22},"functions":{"total":22,"covered":14,"skipped":0,"pct":63.63},"statements":{"total":77,"covered":61,"skipped":0,"pct":79.22},"branches":{"total":30,"covered":16,"skipped":0,"pct":53.33}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/panels/LayersPanel.js": {"lines":{"total":165,"covered":76,"skipped":0,"pct":46.06},"functions":{"total":27,"covered":6,"skipped":0,"pct":22.22},"statements":{"total":171,"covered":77,"skipped":0,"pct":45.02},"branches":{"total":46,"covered":6,"skipped":0,"pct":13.04}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/panels/LeftPanel.js": {"lines":{"total":57,"covered":46,"skipped":0,"pct":80.7},"functions":{"total":20,"covered":15,"skipped":0,"pct":75},"statements":{"total":58,"covered":46,"skipped":0,"pct":79.31},"branches":{"total":32,"covered":12,"skipped":0,"pct":37.5}}
+,"/Users/jfh/Documents/GitHub/svgedit/src/editor/panels/TopPanel.js": {"lines":{"total":409,"covered":310,"skipped":0,"pct":75.79},"functions":{"total":76,"covered":51,"skipped":0,"pct":67.1},"statements":{"total":421,"covered":313,"skipped":0,"pct":74.34},"branches":{"total":209,"covered":126,"skipped":0,"pct":60.28}}
}
diff --git a/cypress/__svgSnapshots__/scenario-check tool_bold.svg b/cypress/__svgSnapshots__/scenario-check tool_bold.svg
index 33fc767d2..6f78b5466 100644
--- a/cypress/__svgSnapshots__/scenario-check tool_bold.svg
+++ b/cypress/__svgSnapshots__/scenario-check tool_bold.svg
@@ -2,6 +2,6 @@
Layer 1
AB
- AB
+ AB
\ No newline at end of file
diff --git a/cypress/__svgSnapshots__/scenario-check tool_clone.svg b/cypress/__svgSnapshots__/scenario-check tool_clone.svg
index 49a40a1ea..8356343ee 100644
--- a/cypress/__svgSnapshots__/scenario-check tool_clone.svg
+++ b/cypress/__svgSnapshots__/scenario-check tool_clone.svg
@@ -2,6 +2,6 @@
Layer 1
AB
- AB
+ AB
\ No newline at end of file
diff --git a/cypress/__svgSnapshots__/scenario-check tool_italic.svg b/cypress/__svgSnapshots__/scenario-check tool_italic.svg
index 67f60f7e9..884cb0cc8 100644
--- a/cypress/__svgSnapshots__/scenario-check tool_italic.svg
+++ b/cypress/__svgSnapshots__/scenario-check tool_italic.svg
@@ -2,6 +2,6 @@
Layer 1
AB
- AB
+ AB
\ No newline at end of file
diff --git a/cypress/__svgSnapshots__/scenario-check tool_text_align_to_page.svg b/cypress/__svgSnapshots__/scenario-check tool_text_align_to_page.svg
index 490ababf5..614975fd1 100644
--- a/cypress/__svgSnapshots__/scenario-check tool_text_align_to_page.svg
+++ b/cypress/__svgSnapshots__/scenario-check tool_text_align_to_page.svg
@@ -2,7 +2,7 @@
Layer 1
AB
- AB
+ AB
diff --git a/cypress/__svgSnapshots__/scenario-check tool_text_change_blur.svg b/cypress/__svgSnapshots__/scenario-check tool_text_change_blur.svg
index 3cd30e527..3384e2b0e 100644
--- a/cypress/__svgSnapshots__/scenario-check tool_text_change_blur.svg
+++ b/cypress/__svgSnapshots__/scenario-check tool_text_change_blur.svg
@@ -2,7 +2,7 @@
Layer 1
AB
- AB
+ AB
diff --git a/cypress/__svgSnapshots__/scenario-check tool_text_change_font_size.svg b/cypress/__svgSnapshots__/scenario-check tool_text_change_font_size.svg
index 577070c99..eb930043e 100644
--- a/cypress/__svgSnapshots__/scenario-check tool_text_change_font_size.svg
+++ b/cypress/__svgSnapshots__/scenario-check tool_text_change_font_size.svg
@@ -2,6 +2,6 @@
Layer 1
AB
- AB
+ AB
\ No newline at end of file
diff --git a/cypress/__svgSnapshots__/scenario-check tool_text_change_opacity.svg b/cypress/__svgSnapshots__/scenario-check tool_text_change_opacity.svg
index d85cc40d6..f4f5cffb5 100644
--- a/cypress/__svgSnapshots__/scenario-check tool_text_change_opacity.svg
+++ b/cypress/__svgSnapshots__/scenario-check tool_text_change_opacity.svg
@@ -2,7 +2,7 @@
Layer 1
AB
- AB
+ AB
diff --git a/cypress/__svgSnapshots__/scenario-check tool_text_change_stoke_fill_color.svg b/cypress/__svgSnapshots__/scenario-check tool_text_change_stoke_fill_color.svg
index e6fb49891..9f4570fc9 100644
--- a/cypress/__svgSnapshots__/scenario-check tool_text_change_stoke_fill_color.svg
+++ b/cypress/__svgSnapshots__/scenario-check tool_text_change_stoke_fill_color.svg
@@ -2,6 +2,6 @@
Layer 1
AB
- AB
+ AB
\ No newline at end of file
diff --git a/cypress/__svgSnapshots__/scenario-check tool_text_change_stroke_width.svg b/cypress/__svgSnapshots__/scenario-check tool_text_change_stroke_width.svg
index 5710c7e0f..8bdb91833 100644
--- a/cypress/__svgSnapshots__/scenario-check tool_text_change_stroke_width.svg
+++ b/cypress/__svgSnapshots__/scenario-check tool_text_change_stroke_width.svg
@@ -2,6 +2,6 @@
Layer 1
AB
- AB
+ AB
\ No newline at end of file
diff --git a/cypress/__svgSnapshots__/scenario-check tool_text_change_x_y_coordinate.svg b/cypress/__svgSnapshots__/scenario-check tool_text_change_x_y_coordinate.svg
index b8fa5cbc1..8aa197965 100644
--- a/cypress/__svgSnapshots__/scenario-check tool_text_change_x_y_coordinate.svg
+++ b/cypress/__svgSnapshots__/scenario-check tool_text_change_x_y_coordinate.svg
@@ -2,6 +2,6 @@
Layer 1
AB
- AB
+ AB
\ No newline at end of file
diff --git a/packages/svgcanvas/core/coords.js b/packages/svgcanvas/core/coords.js
index 7a1961b1a..508418332 100644
--- a/packages/svgcanvas/core/coords.js
+++ b/packages/svgcanvas/core/coords.js
@@ -124,7 +124,7 @@ export const remapElement = (selected, changes, m) => {
case 'image': {
// Allow images to be inverted (give them matrix when flipped)
if (elName === 'image' && (m.a < 0 || m.d < 0)) {
- // Convert to matrix
+ // Convert to matrix if flipped
const chlist = getTransformList(selected)
const mt = svgCanvas.getSvgRoot().createSVGTransform()
mt.setMatrix(matrixMultiply(transformListToTransform(chlist).matrix, m))
@@ -177,6 +177,19 @@ export const remapElement = (selected, changes, m) => {
const pt = remap(changes.x, changes.y)
changes.x = pt.x
changes.y = pt.y
+
+ // Scale font-size
+ let fontSize = selected.getAttribute('font-size')
+ if (!fontSize) {
+ // If not directly set, try computed style
+ fontSize = window.getComputedStyle(selected).fontSize
+ }
+ const fontSizeNum = parseFloat(fontSize)
+ if (!isNaN(fontSizeNum)) {
+ // Assume uniform scaling and use m.a
+ changes['font-size'] = fontSizeNum * Math.abs(m.a)
+ }
+
finishUp()
// Handle child 'tspan' elements
@@ -197,7 +210,17 @@ export const remapElement = (selected, changes, m) => {
const childPtY = remap(changes.x, childY).y
childChanges.y = childPtY
}
- if (hasX || hasY) {
+
+ let tspanFS = child.getAttribute('font-size')
+ if (!tspanFS) {
+ tspanFS = window.getComputedStyle(child).fontSize
+ }
+ const tspanFSNum = parseFloat(tspanFS)
+ if (!isNaN(tspanFSNum)) {
+ childChanges['font-size'] = tspanFSNum * Math.abs(m.a)
+ }
+
+ if (hasX || hasY || childChanges['font-size']) {
assignAttributes(child, childChanges, 1000, true)
}
}
@@ -208,6 +231,17 @@ export const remapElement = (selected, changes, m) => {
const pt = remap(changes.x, changes.y)
changes.x = pt.x
changes.y = pt.y
+
+ // Handle tspan font-size scaling
+ let tspanFS = selected.getAttribute('font-size')
+ if (!tspanFS) {
+ tspanFS = window.getComputedStyle(selected).fontSize
+ }
+ const tspanFSNum = parseFloat(tspanFS)
+ if (!isNaN(tspanFSNum)) {
+ changes['font-size'] = tspanFSNum * Math.abs(m.a)
+ }
+
finishUp()
break
}
diff --git a/packages/svgcanvas/core/event.js b/packages/svgcanvas/core/event.js
index 7e24d40b1..068c63863 100644
--- a/packages/svgcanvas/core/event.js
+++ b/packages/svgcanvas/core/event.js
@@ -570,6 +570,7 @@ const mouseOutEvent = () => {
* @returns {void}
*/
const mouseUpEvent = (evt) => {
+ evt.preventDefault()
moveSelectionThresholdReached = false
if (evt.button === 2) { return }
if (!svgCanvas.getStarted()) { return }
diff --git a/packages/svgcanvas/core/text-actions.js b/packages/svgcanvas/core/text-actions.js
index 9832324ae..73fd209cf 100644
--- a/packages/svgcanvas/core/text-actions.js
+++ b/packages/svgcanvas/core/text-actions.js
@@ -6,33 +6,31 @@
*/
import { NS } from './namespaces.js'
+import { transformPoint, getMatrix } from './math.js'
import {
- transformPoint, getMatrix
-} from './math.js'
-import {
- assignAttributes, getElement, getBBox as utilsGetBBox
+ assignAttributes,
+ getElement,
+ getBBox as utilsGetBBox
} from './utilities.js'
-import {
- supportsGoodTextCharPos
-} from '../common/browser.js'
+import { supportsGoodTextCharPos } from '../common/browser.js'
let svgCanvas = null
/**
-* @function module:text-actions.init
-* @param {module:text-actions.svgCanvas} textActionsContext
-* @returns {void}
-*/
-export const init = (canvas) => {
+ * @function module:text-actions.init
+ * @param {module:text-actions.svgCanvas} textActionsContext
+ * @returns {void}
+ */
+export const init = canvas => {
svgCanvas = canvas
}
/**
-* Group: Text edit functions
-* Functions relating to editing text elements.
-* @namespace {PlainObject} textActions
-* @memberof module:svgcanvas.SvgCanvas#
-*/
+ * Group: Text edit functions
+ * Functions relating to editing text elements.
+ * @namespace {PlainObject} textActions
+ * @memberof module:svgcanvas.SvgCanvas#
+ */
export const textActionsMethod = (function () {
let curtext
let textinput
@@ -42,23 +40,26 @@ export const textActionsMethod = (function () {
let chardata = []
let textbb // , transbb;
let matrix
- let lastX; let lastY
+ let lastX
+ let lastY
let allowDbl
/**
-*
-* @param {Integer} index
-* @returns {void}
-*/
+ *
+ * @param {Integer} index
+ * @returns {void}
+ */
function setCursor (index) {
- const empty = (textinput.value === '')
+ const empty = textinput.value === ''
textinput.focus()
if (!arguments.length) {
if (empty) {
index = 0
} else {
- if (textinput.selectionEnd !== textinput.selectionStart) { return }
+ if (textinput.selectionEnd !== textinput.selectionStart) {
+ return
+ }
index = textinput.selectionEnd
}
}
@@ -80,13 +81,13 @@ export const textActionsMethod = (function () {
if (!blinker) {
blinker = setInterval(function () {
- const show = (cursor.getAttribute('display') === 'none')
+ const show = cursor.getAttribute('display') === 'none'
cursor.setAttribute('display', show ? 'inline' : 'none')
}, 600)
}
const startPt = ptToScreen(charbb.x, textbb.y)
- const endPt = ptToScreen(charbb.x, (textbb.y + textbb.height))
+ const endPt = ptToScreen(charbb.x, textbb.y + textbb.height)
assignAttributes(cursor, {
x1: startPt.x,
@@ -97,16 +98,18 @@ export const textActionsMethod = (function () {
display: 'inline'
})
- if (selblock) { selblock.setAttribute('d', '') }
+ if (selblock) {
+ selblock.setAttribute('d', '')
+ }
}
/**
-*
-* @param {Integer} start
-* @param {Integer} end
-* @param {boolean} skipInput
-* @returns {void}
-*/
+ *
+ * @param {Integer} start
+ * @param {Integer} end
+ * @param {boolean} skipInput
+ * @returns {void}
+ */
function setSelection (start, end, skipInput) {
if (start === end) {
setCursor(end)
@@ -137,12 +140,29 @@ export const textActionsMethod = (function () {
const tl = ptToScreen(startbb.x, textbb.y)
const tr = ptToScreen(startbb.x + (endbb.x - startbb.x), textbb.y)
const bl = ptToScreen(startbb.x, textbb.y + textbb.height)
- const br = ptToScreen(startbb.x + (endbb.x - startbb.x), textbb.y + textbb.height)
-
- const dstr = 'M' + tl.x + ',' + tl.y +
-' L' + tr.x + ',' + tr.y +
-' ' + br.x + ',' + br.y +
-' ' + bl.x + ',' + bl.y + 'z'
+ const br = ptToScreen(
+ startbb.x + (endbb.x - startbb.x),
+ textbb.y + textbb.height
+ )
+
+ const dstr =
+ 'M' +
+ tl.x +
+ ',' +
+ tl.y +
+ ' L' +
+ tr.x +
+ ',' +
+ tr.y +
+ ' ' +
+ br.x +
+ ',' +
+ br.y +
+ ' ' +
+ bl.x +
+ ',' +
+ bl.y +
+ 'z'
assignAttributes(selblock, {
d: dstr,
@@ -151,11 +171,11 @@ export const textActionsMethod = (function () {
}
/**
-*
-* @param {Float} mouseX
-* @param {Float} mouseY
-* @returns {Integer}
-*/
+ *
+ * @param {Float} mouseX
+ * @param {Float} mouseY
+ * @returns {Integer}
+ */
function getIndexFromPoint (mouseX, mouseY) {
// Position cursor here
const pt = svgCanvas.getSvgRoot().createSVGPoint()
@@ -163,7 +183,9 @@ export const textActionsMethod = (function () {
pt.y = mouseY
// No content, so return 0
- if (chardata.length === 1) { return 0 }
+ if (chardata.length === 1) {
+ return 0
+ }
// Determine if cursor should be on left or right of character
let charpos = curtext.getCharNumAtPosition(pt)
if (charpos < 0) {
@@ -176,7 +198,7 @@ export const textActionsMethod = (function () {
charpos = chardata.length - 2
}
const charbb = chardata[charpos]
- const mid = charbb.x + (charbb.width / 2)
+ const mid = charbb.x + charbb.width / 2
if (mouseX > mid) {
charpos++
}
@@ -184,22 +206,22 @@ export const textActionsMethod = (function () {
}
/**
-*
-* @param {Float} mouseX
-* @param {Float} mouseY
-* @returns {void}
-*/
+ *
+ * @param {Float} mouseX
+ * @param {Float} mouseY
+ * @returns {void}
+ */
function setCursorFromPoint (mouseX, mouseY) {
setCursor(getIndexFromPoint(mouseX, mouseY))
}
/**
-*
-* @param {Float} x
-* @param {Float} y
-* @param {boolean} apply
-* @returns {void}
-*/
+ *
+ * @param {Float} x
+ * @param {Float} y
+ * @param {boolean} apply
+ * @returns {void}
+ */
function setEndSelectionFromPoint (x, y, apply) {
const i1 = textinput.selectionStart
const i2 = getIndexFromPoint(x, y)
@@ -210,11 +232,11 @@ export const textActionsMethod = (function () {
}
/**
-*
-* @param {Float} xIn
-* @param {Float} yIn
-* @returns {module:math.XYObject}
-*/
+ *
+ * @param {Float} xIn
+ * @param {Float} yIn
+ * @returns {module:math.XYObject}
+ */
function screenToPt (xIn, yIn) {
const out = {
x: xIn,
@@ -234,11 +256,11 @@ export const textActionsMethod = (function () {
}
/**
-*
-* @param {Float} xIn
-* @param {Float} yIn
-* @returns {module:math.XYObject}
-*/
+ *
+ * @param {Float} xIn
+ * @param {Float} yIn
+ * @returns {module:math.XYObject}
+ */
function ptToScreen (xIn, yIn) {
const out = {
x: xIn,
@@ -258,22 +280,24 @@ export const textActionsMethod = (function () {
}
/**
-*
-* @param {Event} evt
-* @returns {void}
-*/
+ *
+ * @param {Event} evt
+ * @returns {void}
+ */
function selectAll (evt) {
setSelection(0, curtext.textContent.length)
evt.target.removeEventListener('click', selectAll)
}
/**
-*
-* @param {Event} evt
-* @returns {void}
-*/
+ *
+ * @param {Event} evt
+ * @returns {void}
+ */
function selectWord (evt) {
- if (!allowDbl || !curtext) { return }
+ if (!allowDbl || !curtext) {
+ return
+ }
const zoom = svgCanvas.getZoom()
const ept = transformPoint(evt.pageX, evt.pageY, svgCanvas.getrootSctm())
const mouseX = ept.x * zoom
@@ -297,30 +321,30 @@ export const textActionsMethod = (function () {
return /** @lends module:svgcanvas.SvgCanvas#textActions */ {
/**
-* @param {Element} target
-* @param {Float} x
-* @param {Float} y
-* @returns {void}
-*/
+ * @param {Element} target
+ * @param {Float} x
+ * @param {Float} y
+ * @returns {void}
+ */
select (target, x, y) {
curtext = target
svgCanvas.textActions.toEditMode(x, y)
},
/**
-* @param {Element} elem
-* @returns {void}
-*/
+ * @param {Element} elem
+ * @returns {void}
+ */
start (elem) {
curtext = elem
svgCanvas.textActions.toEditMode()
},
/**
-* @param {external:MouseEvent} evt
-* @param {Element} mouseTarget
-* @param {Float} startX
-* @param {Float} startY
-* @returns {void}
-*/
+ * @param {external:MouseEvent} evt
+ * @param {Element} mouseTarget
+ * @param {Float} startX
+ * @param {Float} startY
+ * @returns {void}
+ */
mouseDown (evt, mouseTarget, startX, startY) {
const pt = screenToPt(startX, startY)
@@ -332,20 +356,20 @@ export const textActionsMethod = (function () {
// TODO: Find way to block native selection
},
/**
-* @param {Float} mouseX
-* @param {Float} mouseY
-* @returns {void}
-*/
+ * @param {Float} mouseX
+ * @param {Float} mouseY
+ * @returns {void}
+ */
mouseMove (mouseX, mouseY) {
const pt = screenToPt(mouseX, mouseY)
setEndSelectionFromPoint(pt.x, pt.y)
},
/**
-* @param {external:MouseEvent} evt
-* @param {Float} mouseX
-* @param {Float} mouseY
-* @returns {void}
-*/
+ * @param {external:MouseEvent} evt
+ * @param {Float} mouseX
+ * @param {Float} mouseY
+ * @returns {void}
+ */
mouseUp (evt, mouseX, mouseY) {
const pt = screenToPt(mouseX, mouseY)
@@ -359,25 +383,25 @@ export const textActionsMethod = (function () {
if (
evt.target !== curtext &&
- mouseX < lastX + 2 &&
- mouseX > lastX - 2 &&
- mouseY < lastY + 2 &&
- mouseY > lastY - 2
+ mouseX < lastX + 2 &&
+ mouseX > lastX - 2 &&
+ mouseY < lastY + 2 &&
+ mouseY > lastY - 2
) {
svgCanvas.textActions.toSelectMode(true)
}
},
/**
-* @function
-* @param {Integer} index
-* @returns {void}
-*/
+ * @function
+ * @param {Integer} index
+ * @returns {void}
+ */
setCursor,
/**
-* @param {Float} x
-* @param {Float} y
-* @returns {void}
-*/
+ * @param {Float} x
+ * @param {Float} y
+ * @returns {void}
+ */
toEditMode (x, y) {
allowDbl = false
svgCanvas.setCurrentMode('textedit')
@@ -407,16 +431,20 @@ export const textActionsMethod = (function () {
}, 300)
},
/**
-* @param {boolean|Element} selectElem
-* @fires module:svgcanvas.SvgCanvas#event:selected
-* @returns {void}
-*/
+ * @param {boolean|Element} selectElem
+ * @fires module:svgcanvas.SvgCanvas#event:selected
+ * @returns {void}
+ */
toSelectMode (selectElem) {
svgCanvas.setCurrentMode('select')
clearInterval(blinker)
blinker = null
- if (selblock) { selblock.setAttribute('display', 'none') }
- if (cursor) { cursor.setAttribute('visibility', 'hidden') }
+ if (selblock) {
+ selblock.setAttribute('display', 'none')
+ }
+ if (cursor) {
+ cursor.setAttribute('visibility', 'hidden')
+ }
curtext.style.cursor = 'move'
if (selectElem) {
@@ -440,27 +468,30 @@ export const textActionsMethod = (function () {
// }
},
/**
-* @param {Element} elem
-* @returns {void}
-*/
+ * @param {Element} elem
+ * @returns {void}
+ */
setInputElem (elem) {
textinput = elem
},
/**
-* @returns {void}
-*/
+ * @returns {void}
+ */
clear () {
if (svgCanvas.getCurrentMode() === 'textedit') {
svgCanvas.textActions.toSelectMode()
}
},
/**
-* @param {Element} _inputElem Not in use
-* @returns {void}
-*/
+ * @param {Element} _inputElem Not in use
+ * @returns {void}
+ */
init (_inputElem) {
- if (!curtext) { return }
- let i; let end
+ if (!curtext) {
+ return
+ }
+ let i
+ let end
// if (supportsEditableText()) {
// curtext.select();
// return;
@@ -490,7 +521,7 @@ export const textActionsMethod = (function () {
curtext.addEventListener('dblclick', selectWord)
if (!len) {
- end = { x: textbb.x + (textbb.width / 2), width: 0 }
+ end = { x: textbb.x + textbb.width / 2, width: 0 }
}
for (i = 0; i < len; i++) {
@@ -527,4 +558,4 @@ export const textActionsMethod = (function () {
setSelection(textinput.selectionStart, textinput.selectionEnd, true)
}
}
-}())
+})()