0 Replies Latest reply on Jun 24, 2013 7:18 AM by shilpa25

    Couldn't able to re-transform

    shilpa25 Level 1

      HI forum,


      This a great request from you.


      I have added a rectangle box. and I'm grouped the page items.


      I have already transformed the group. and again i want to transform the group with added rectangle box height.


      I tried many more times, but no result.



      //getting height of the added rectangle.

      rc3 = app.activeDocument.pages.item(0).rectangles.add();

      rc3.geometricBounds =[rc.geometricBounds[2], rc3.geometricBounds[1], mT, rc3.geometricBounds[3]+20];

      hfc1 = rc3.geometricBounds;

      var hfc2 = hfc1[2]-hfc1[0];



      //getting height of the group

      gr2 = app.activeDocument.pageItems.everyItem();

      var gr3 = app.activeDocument.groups.add(gr2);

      var bgr4 = gr3.geometricBounds;

      var hgr4 = bgr4[2]-bgr4[0]; //getting the height of the group...



      //adding the height of the added rectangle to the group to transform....but nothing happenedd.


      var hn1 = bgr4+hfc2;

      tM1 = app.transformationMatrices.add({horizontalScaleFactor: hn1,   verticalScaleFactor:hn1}); 

                 gr3.transform(CoordinateSpaces.INNER_COORDINATES,   AnchorPoint.BOTTOM_CENTER_ANCHOR, tM1);


      Help please.!