Getting a list of object properties

J. Landman Gay jacque at hyperactivesw.com
Thu Oct 9 16:35:50 EDT 2014


On 10/9/2014, 3:09 PM, William Prothero wrote:
> Wouldn’t it be great for newbies to have a tab in the object
> inspector that listed all of the settable property names and
> messages? Yes, some are shown in the BvG Docu 2 app, but it’s
> incomplete.

You can see all the properties of any object in the dictionary:

1. Select the object in left-hand column.
2. Click the "Type" header in the keyword list. That sorts the list by 
type, and all the properties will be displayed together.

As an aside, if you want to see information that isn't already shown, 
look in Preferences in the Documentation pane. You can set the types of 
information you want to display in the dictionary. There are more 
choices than just the defaults.

>
> If I do:
> put the properties of scrollbar “axisEntry"
> I don’t get anything in the message box. LC7.0 rC2, Mavericks.

That's because the properties are an array, which can't be displayed in 
the message box. You can write a little handler that lets you see them 
in the debugger though (which is my usual shortcut when I need to see 
something temporarily):

on showProperties pObj
  get the properties of pObj
  breakpoint
end showProperties

Call it like this: showProperties the long name of scrollbar 1

Or revise it to combine the array and put the resulting text into a 
field somewhere.

-- 
Jacqueline Landman Gay         |     jacque at hyperactivesw.com
HyperActive Software           |     http://www.hyperactivesw.com





More information about the use-livecode mailing list