1 Reply Latest reply on Aug 7, 2014 8:03 PM by wygyj

    PS cxsx layer translate method

    wygyj Level 1

      The definition of method is:

           public function translate(deltaX:Object = null, deltaY:Object = null):void

           deltaX:Object (default = null) — (Object) horizontal transformation (unit value)

           deltaY:Object (default = null) — (Object) vertical transformation (unit value)

      see in CC Application SDK

      How do I set the arguments? Object is what? I am developing PS extension with Adobe Extension Builder using ActionScript.

      By the way, if you konw how to use Layer.move() method, please tell me how to use it. Thank YOU!

        • 1. Re: PS cxsx layer translate method
          wygyj Level 1

          I have found what the object is. The object is that value with units like "10 px" or "10 in" in string format. And you can just use 10(int) or 10(Number) as arguments, this's ok too. But if you use it without units, you must set the application's units to what you want like below.

               app.preferences.rulerUnits = Units.PIXELS;

          The code above set the units to pixels in Photoshop. You can set another units also.