ActionManager Descriptor Keys

Upload Area - Upload Files Here, link to them from the appropriate Forum

Moderators: Tom, Kukurykus

Mike Hale

ActionManager Descriptor Keys

Post by Mike Hale »

I'm working on putting together a pdf of descriptor keys. Here is a sample of layer keys.

Does anyone besides me have an interest in seeing the final pdf?

Mike
xbytor

ActionManager Descriptor Keys

Post by xbytor »

I'm definitely interested.

I do have one question:
In your doc, the table implies that cTID('Nm ') and sTID('Name') are equivalent. They actually generate two different ID values.

If you look in PSConstants, there are lines like this:

Code: Select allPSKey._add("Name", "Nm  ");

The first arg is the human readable form (the name), while the second is the 4 letter key (the symbol aka the character code) that you pass to cTID to get the runtime ID.

Strings are handled differently. Again, from PSConstants:

Code: Select allPSString._add("layerName");
PSString._add("layerGroup", "layerSection");


In most sTID/PSString entries, the name is the same as the symbol as is the case with layerName. This makes things nice and readable.

The layerGroup/layerSection is a bit different. This mapping means that layerGroup is the public name and that it's ID is actually the same sTID as layerSection. It's kind of like a preprocessor substitution takes place. As a result, you have two different strings with the same ID.

-X
Mike Hale

ActionManager Descriptor Keys

Post by Mike Hale »

xbytor wrote:In your doc, the table implies that cTID('Nm ') and sTID('Name') are equivalent. They actually generate two different ID values.

You may be right. The info in the table comes from getterdemo output so it may be showing the results of your mapping in PSConstants. It also could be that I mistyped the sTID. If you run the following

Code: Select alltypeIDToStringID(charIDToTypeID('Nm  '))

It returns 'name'.

At this stage, I'm just gathering the keys so I will keep that in mind as a double check.

One of the things I would like to do with this is list as many keys as I can find. I'm just not sure how to display the data. For example bounds is one of the top level keys for a layer. And the bounds descriptor has 4 keys. Any thought on how to show them in the pdf?

Mike