DTYPE_GROUP unfolded [SOLVED]
-
On 24/02/2015 at 01:42, xxxxxxxx wrote:
User Information:
Cinema 4D Version: 13+
Platform: Windows ; Mac ; Mac OSX ;
Language(s) : C++ ;---------
Hi,1. Any idea how I can force an open/closed state of a (sub)group?
2. And maybe I would also appreciate to know what DESC_ASKOBJECT actually does.Thanks!
Edit: solution for 1. is DESC_DEFAULT and not DESC_GUIOPEN as I initially thought. Still would like to know about DESC_ASKOBJECT for future reference. Thanks!
Edit: Hmm, also setting DESC_DEFAULT to TRUE (am using SetBool(DESC_DEFAULT,true)) when adding a group dynamically does not necessarily make it being open. So the question 1. remains. Any idea?
-
On 24/02/2015 at 03:47, xxxxxxxx wrote:
As a follow up question, is there a way to determine if a group is currently open or closed
But Question 1. above has highest priority for me...the others would only be nice to know! -
On 24/02/2015 at 06:38, xxxxxxxx wrote:
Hello,
the parameter description is just that – the description of the properties the parameter has, but no description of it's current state. That description is used by GUI elements to display the parameters and allow user interaction. Especially the DescriptionCustomGui element is in charge of displaying the parameters. If a group is folded or not is just handled inside that GUI element and is not stored in the parameter or it's description.
In fact, you can create multiple Attribute Manager instances linking to the same object. In one Attribute Manager a certain group may be folded, in another instance the same group is not. So the attribute manager is just a view on the object and does not change it (at least folding groups is no change of the object). So the object cannot know if in some GUI somewhere a group is folded or not.
But you can set DESC_DEFAULT to -1. This will enable a "Sticky Mode". Then the group is always unfolded when it is handled by the GUI. But this cannot prevent the group from being closed by user interaction.
DESC_ASKOBJECT is currently not used and does nothing.
best wishes,
Sebastian -
On 24/02/2015 at 10:54, xxxxxxxx wrote:
Hi
Originally posted by xxxxxxxx
[...] So the object cannot know if in some GUI somewhere a group is folded or not.
That's true, I didn't think of the availability of several AM dialogs which would probably have given me that answer itself Thanks!
But you can set DESC_DEFAULT to -1. This will enable a "Sticky Mode". Then the group is always unfolded when it is handled by the GUI. But this cannot prevent the group from being closed by user interaction.
DESC_ASKOBJECT is currently not used and does nothing.
best wishes,
SebastianThanks Sebastian. That's exactly what I needed and it seems to work just fine!
Also thanks for the info on ASKOBJECT.Best
Samir