Jump to content

Change property node from read to write


Recommended Posts

Posted

I'm creating dozens of property nodes via scripting.  They get placed as "read" nodes by default.  There doesn't seem to be an option to programmatically change them to write.  Am I missing something or is this simply functionality that's not currently available?

 

Thanks

  • 5 years later...
Posted

Get the desired PropertyItem from the Properties[] property of the Property Node reference.  Then you can set the isWrite property as desired.

  • Thanks 1
Posted (edited)

This is for a quick drop plugin, and I'm getting my references from the panel selection list. Generally, I use a "To more specific class" to get specific class reference type and thus the appropriate methods or property nodes, based on the ClassName. The ClassName I'm getting is "Property".

The problem I was having is that I couldn't find the specific class I needed for the "To more specific class" function. The answer is, Generic->GObject->Node->Growable Function-> Object Function->Property.

From there you get the PropertyItems[] list via property node and iterate through that, toggling the IsWrite property.

Edited by meubanks
  • Thanks 1

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.