Skip to main content
greless
Inspiring
March 5, 2019
Answered

could we get the property of the Clone Source pannel?

  • March 5, 2019
  • 1 reply
  • 1117 views

so  how to get the property?

This topic has been closed for replies.
Correct answer r-bin

I also found some parameters of the panel (in CC2018), but there is nothing that is of high interest in the resulting descriptor.

var d = new ActionDescriptor();

var r = new ActionReference();      

r.putEnumerated(stringIDToTypeID("application"), stringIDToTypeID("ordinal"), stringIDToTypeID("targetEnum"));

d.putReference(stringIDToTypeID("null"), r);  

d.putString (stringIDToTypeID("command"), "getViewInfo");  

d.putString (stringIDToTypeID("viewID"), "$clnS");  

d.putString (stringIDToTypeID("panel"), "clonesource");

var ret = executeAction(stringIDToTypeID("uiInfo"), d, DialogModes.NO);

1 reply

Legend
March 5, 2019

Theoretically, yes, because there are such IDs.

"cloneSource",
"cloneSourceAutoHideOverlay",
"cloneSourceInvertOverlay",
"cloneSourceLockFrame",
"cloneSourceResetTransform",
"cloneSourceShowOverlay",
"cloneSourceClipOverlay",
"cloneSourceSource1",
"cloneSourceSource2",
"cloneSourceSource3",
"cloneSourceSource4",
"cloneSourceSource5",
"cloneSourceToolOptions",

But most likely, not, since Adobe again forgot to screw it to the scripts or to ActionManager.

greless
grelessAuthor
Inspiring
March 5, 2019

it's alright ,How do i use these?at present i just get the name/ID/visible/obscured from  "panelList".

var ref = new ActionReference();

ref.putEnumerated( charIDToTypeID("capp"), charIDToTypeID("Ordn"), charIDToTypeID("Trgt") );

var applicationDesc = executeActionGet(ref);

var thePanelList = applicationDesc.getList(stringIDToTypeID("panelList"));

var thePanels = new Array;

for (var m = 0; m < thePanelList.count; m++) {

thePanels.push(checkDesc2 (thePanelList.getObjectValue(m)));

};

.........

output:

Key 0 = name: DescValueType.STRINGTYPE

Clone Source

Key 1 = ID: DescValueType.STRINGTYPE

panelid.static.clonesource

Key 2 = visible: DescValueType.BOOLEANTYPE

true

Key 3 = obscured: DescValueType.BOOLEANTYPE

false

Legend
March 5, 2019

And there is nothing more

And by the way most of these IDs (see above) work. This is the menu IDs.