Commit d57e03c5111d0a0e8069cf10efd202b95613e82d

Authored by unknown
1 parent 4304b2f6

DA > Annotation Toolbar > Text write in the text box display out from the box wh…

…en user reverse draw the text box.
400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js
... ... @@ -1178,8 +1178,8 @@ function ($rootScope, Modules, $log, $location, $timeout, DataService, Authentic
1178 1178 strokeWidth: shapestyleborderWidth,
1179 1179 fromCenter: false,
1180 1180 x: offsetX1, y: offsetY1,
1181   - width: (x - offsetX1),
1182   - height: (y - offsetY1),
  1181 + width: Math.abs(x - offsetX1),
  1182 + height: Math.abs(y - offsetY1),
1183 1183  
1184 1184 resizeFromCenter: false,
1185 1185  
... ... @@ -1275,7 +1275,7 @@ function ($rootScope, Modules, $log, $location, $timeout, DataService, Authentic
1275 1275 fillStyle: shapestyleFillColor,
1276 1276 fromCenter: false,
1277 1277 x: (offsetX1), y: (offsetY1),
1278   - width: (x - offsetX1), height: (y - offsetY1),
  1278 + width: Math.abs(x - offsetX1), height: Math.abs(y - offsetY1),
1279 1279 // Place a handle at each side and each corner
1280 1280 resizeFromCenter: false,
1281 1281 handlePlacement: 'both',
... ... @@ -1604,8 +1604,8 @@ function ($rootScope, Modules, $log, $location, $timeout, DataService, Authentic
1604 1604 strokeWidth: $rootScope.shapestyleborderWidth,
1605 1605 fillStyle: $rootScope.shapestyleFillColor,
1606 1606 x: $rootScope.offsetX1, y: $rootScope.offsetY1,
1607   - width: ($rootScope.x - $rootScope.offsetX1),
1608   - height: ($rootScope.y - $rootScope.offsetY1),
  1607 + width: Math.abs($rootScope.x - $rootScope.offsetX1),
  1608 + height: Math.abs($rootScope.y - $rootScope.offsetY1),
1609 1609 resizeFromCenter: false,
1610 1610 add: function (layer) {
1611 1611  
... ... @@ -2005,8 +2005,8 @@ function ($rootScope, Modules, $log, $location, $timeout, DataService, Authentic
2005 2005 fillStyle: $rootScope.selectedBGColorForTextArea,
2006 2006 fromCenter: false,
2007 2007 x: $rootScope.rectDimension[$rootScope.rectDimension.length - 1].x, y: $rootScope.rectDimension[$rootScope.rectDimension.length - 1].y,
2008   - width: $rootScope.rectDimension[$rootScope.rectDimension.length - 1].width,
2009   - height: $rootScope.rectDimension[$rootScope.rectDimension.length - 1].height,
  2008 + width: Math.abs($rootScope.rectDimension[$rootScope.rectDimension.length - 1].width),
  2009 + height: Math.abs($rootScope.rectDimension[$rootScope.rectDimension.length - 1].height),
2010 2010 resizeFromCenter: false,
2011 2011 add: function (layer) {
2012 2012 var TextAreaLayerName = layer.name;
... ... @@ -2269,8 +2269,8 @@ function ($rootScope, Modules, $log, $location, $timeout, DataService, Authentic
2269 2269 strokeWidth: 0,
2270 2270 text: $rootScope.textArea,
2271 2271 x: ($rootScope.rectDimension[$rootScope.rectDimension.length - 1].x), y: $rootScope.rectDimension[$rootScope.rectDimension.length - 1].y,
2272   - maxWidth: $rootScope.rectDimension[$rootScope.rectDimension.length - 1].width,
2273   - maxHeight: $rootScope.rectDimension[$rootScope.rectDimension.length - 1].height,
  2272 + maxWidth: Math.abs($rootScope.rectDimension[$rootScope.rectDimension.length - 1].width),
  2273 + maxHeight: Math.abs($rootScope.rectDimension[$rootScope.rectDimension.length - 1].height),
2274 2274 add: function (layer) {
2275 2275 // console.log(layer.x + " " + layer.y);
2276 2276 $rootScope.textXAxisAftrResize = layer.x;
... ... @@ -2345,8 +2345,8 @@ function ($rootScope, Modules, $log, $location, $timeout, DataService, Authentic
2345 2345 strokeWidth: $rootScope.shapestyleborderWidth,
2346 2346 fillStyle: $rootScope.selectedBGColorForTextArea,
2347 2347 x: $rootScope.rectDimension[$rootScope.rectDimension.length - 1].x, y: $rootScope.rectDimension[$rootScope.rectDimension.length - 1].y,
2348   - width: $rootScope.rectDimension[$rootScope.rectDimension.length - 1].width,
2349   - height: $rootScope.rectDimension[$rootScope.rectDimension.length - 1].height,
  2348 + width: Math.abs($rootScope.rectDimension[$rootScope.rectDimension.length - 1].width),
  2349 + height: Math.abs($rootScope.rectDimension[$rootScope.rectDimension.length - 1].height),
2350 2350 resizeFromCenter: false,
2351 2351 add: function (layer) {
2352 2352 var TextAreaLayerName = layer.name;
... ... @@ -2563,8 +2563,8 @@ function ($rootScope, Modules, $log, $location, $timeout, DataService, Authentic
2563 2563 fromCenter: false,
2564 2564 text: _modifiedText,
2565 2565 x: $rootScope.rectDimension[$rootScope.rectDimension.length - 1].x, y: $rootScope.rectDimension[$rootScope.rectDimension.length - 1].y,
2566   - maxWidth: $rootScope.rectDimension[$rootScope.rectDimension.length - 1].width,
2567   - maxHeight: $rootScope.rectDimension[$rootScope.rectDimension.length - 1].height,
  2566 + maxWidth: Math.abs($rootScope.rectDimension[$rootScope.rectDimension.length - 1].width),
  2567 + maxHeight: Math.abs($rootScope.rectDimension[$rootScope.rectDimension.length - 1].height),
2568 2568 add: function (layer) {
2569 2569 // console.log(layer.x + " " + layer.y);
2570 2570 $rootScope.editTextXAxisAftrResize = layer.x;
... ...