I am using draw2dtouch
6.1.66 version
(latest version). Initially width and height of canvas was 1000px
and 800px
respectively. On button click, I am changing the canvas width and height to 2170px
and 902px
respectively.
Now I cannot drag rectangle figure beyond 1000px
width-wise. It gets stuck to 1000px
which was initial width.
Note: I check my html, both canvas div and svg shows width:2170px
and height:902px
.
<div _ngcontent-awi-17="" draw2d-canvas="" id="canvas" style="height: 902px; cursor: default; -webkit-tap-highlight-color: rgba(0, 0, 0, 0); width: 2170px;">
<svg height="902" version="1.1" width="2170" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" style="overflow: hidden; position: absolute; left: -0.828125px;">
Here is my code:
$("#canvas").css("height",902);
$("#canvas").css("width", 2170);
canvas.setDimension(new draw2d.geo.Rectangle(0, 0, 2170, 902));