diff --git a/web/app/sketcher/sketcher-app.js b/web/app/sketcher/sketcher-app.js index 723b01bd..65f532cf 100644 --- a/web/app/sketcher/sketcher-app.js +++ b/web/app/sketcher/sketcher-app.js @@ -27,17 +27,21 @@ function App2D() { this._actionsOrder = []; var dockEl = $('#dock'); - var statusEl = $('#status'); - this.dock = new ui.Dock(dockEl, statusEl, App2D.views); + var buttonGroup = $('#status .button-group'); + this.dock = new ui.Dock(dockEl, buttonGroup, App2D.views); this.dock.show('Constraints'); var consoleBtn = ui.dockBtn('Commands', 'list'); - statusEl.append(consoleBtn); + buttonGroup.append(consoleBtn); var commandsWin = new ui.Window($('#commands'), this.winManager); commandsWin.tileUpRelative = $('#viewer'); consoleBtn.click(function() { commandsWin.toggle(); }); + $(document).on('mousemove', '#viewer', (e) => { + let coord = this.viewer.screenToModel(e); + $('.coordinates-info').text(coord.x.toFixed(3) + " : " + coord.y.toFixed(3)); + }); new ui.Terminal(commandsWin, function(command) { return "Command " + command + " executed"; }); diff --git a/web/css/app.css b/web/css/app.css index ceaa7308..81f7facd 100644 --- a/web/css/app.css +++ b/web/css/app.css @@ -55,9 +55,6 @@ html, body { border:0 solid black; background: #606060 no-repeat center; border-radius: 4px; - color: white; - font-size: 11px; - font-family: 'Helvetica Neue Light', HelveticaNeue-Light, 'Helvetica Neue', Helvetica, sans-serif; cursor: pointer; margin: 1px 4px 1px 4px; } @@ -303,4 +300,16 @@ html, body { input[type=checkbox], input[type=radio] { vertical-align: middle; +} + +#status { + font-family: 'Helvetica Neue Light', HelveticaNeue-Light, 'Helvetica Neue', Helvetica, sans-serif; + color: white; + font-size: 11px; + padding-top: 5px; +} + +#status .coordinates-info { + padding-right: 5px; + font-style: italic; } \ No newline at end of file diff --git a/web/sketcher.html b/web/sketcher.html index 8593a8ee..9f07802e 100644 --- a/web/sketcher.html +++ b/web/sketcher.html @@ -64,8 +64,12 @@ -