Hi,
I have a CEP panel that i’m trying to convert to UXP. I had a fonction that change the color of the selected text layer.
Using Alchemist for Photoshop, i can get the batchPlay function and properties, and i’m able to change the color of the text, however it also chage every property of the text layer (font, size, kerning etc). If i dont put these property, they reset to a default state, which also change all the properties.
Anybody know how to change a property without affecting all the others ?
batchPlay(
[{
"_obj": "set",
"_target": [{
"_ref": "layer",
"_enum": "ordinal",
"_value": "targetEnum"
}],
"to": {
"_obj": "textLayer",
"textStyleRange": [
{
"_obj": "textStyleRange",
"from": 0,
"to": 10,
"textStyle": {
"_obj": "textStyle",
"color": {
"_obj": "RGBColor",
"red": 0,
"grain": 0,
"blue": 0
}
}
}]
},
"_isCommand": true,
"_options": {
"dialogOptions": "dontDisplay"
}
}
],{
"synchronousExecution": false,
"modalBehavior": "fail"
});