There are many key board shortcuts and many I can see are closly related to script methods. What I don't see though is a way to execute a shortcut in a script. For example, to create a composite artlayer of all layers below the active layer I can use a shortcut, SHIFT-CTRL-ALT-E (PC). I do not know how to make photoshop do that from a script so I am wondering is there is a way to simply have the script execute the shortcut? This could be generalized to all shortcuts of course.
Have I missed a manual somewhere (I am a newbie)? Thanks.
Executing keyboard shortcut functions
Executing keyboard shortcut functions
There is a plug-in named scriptlistener that will record most menu or keyboard command to a log that then can be used in a script. Details are in the javascript guide.
Here is the merge visible into new layer code.
Code: Select allvar desc = new ActionDescriptor();
desc.putBoolean( charIDToTypeID('Dplc'), true );
executeAction( charIDToTypeID('MrgV'), desc, DialogModes.NO );
Here is the merge visible into new layer code.
Code: Select allvar desc = new ActionDescriptor();
desc.putBoolean( charIDToTypeID('Dplc'), true );
executeAction( charIDToTypeID('MrgV'), desc, DialogModes.NO );