Created
January 18, 2021 22:45
-
-
Save silicontrip/069e7b4010fb816e4fbd58af5c1904f6 to your computer and use it in GitHub Desktop.
rectangle selection photoshop
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var idsetd = charIDToTypeID( "setd" ); | |
var desc12 = new ActionDescriptor(); | |
var idnull = charIDToTypeID( "null" ); | |
var ref1 = new ActionReference(); | |
var idChnl = charIDToTypeID( "Chnl" ); | |
var idfsel = charIDToTypeID( "fsel" ); | |
ref1.putProperty( idChnl, idfsel ); | |
desc12.putReference( idnull, ref1 ); | |
var idT = charIDToTypeID( "T " ); | |
var desc13 = new ActionDescriptor(); | |
var idTop = charIDToTypeID( "Top " ); | |
var idPxl = charIDToTypeID( "#Pxl" ); | |
desc13.putUnitDouble( idTop, idPxl, 3268.000000 ); | |
var idLeft = charIDToTypeID( "Left" ); | |
var idPxl = charIDToTypeID( "#Pxl" ); | |
desc13.putUnitDouble( idLeft, idPxl, 1328.000000 ); | |
var idBtom = charIDToTypeID( "Btom" ); | |
var idPxl = charIDToTypeID( "#Pxl" ); | |
desc13.putUnitDouble( idBtom, idPxl, 3716.000000 ); | |
var idRght = charIDToTypeID( "Rght" ); | |
var idPxl = charIDToTypeID( "#Pxl" ); | |
desc13.putUnitDouble( idRght, idPxl, 5040.000000 ); | |
var idRctn = charIDToTypeID( "Rctn" ); | |
desc12.putObject( idT, idRctn, desc13 ); | |
executeAction( idsetd, desc12, DialogModes.NO ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
An xml object representing the
ActionDescriptor
used for selecting (setting) a rectangular marquee. Based on the Apple.plist
structure. This format more accurately represents theActionDescriptor
than the previous description, in both the order of the keys isn't important and that a text values type can accurately specified also nested objects can be represented. This could be programmatically converted into a Descriptor object suitable for sending to theexecuteAction
function. These XML files were generated programmatically, from anexecuteAction
call.