On 19/06/2017 at 10:41, xxxxxxxx wrote:
Cinema 4D Version: 18
Platform: Windows ; Mac ;
Language(s) : C++ ;
I'm trying to figure out how to hide a parameter in an object generator plugin, but I can't for the life of me figure out how to do this or how to get a pointer to some UI widget to hide one of it's children.
The whole plugin UI is created using description resources ".res, str..etc" files.
This makes cinema 4d create a UI based on these files, does c4d has another way of creating the UI the ordinary way ?
like creating a widget -> add child widgets -> set child widgets properties..etc ?
What I am trying to achieve is to show some parameters based on a selection in a tree widget and
to hide them if the tree widget doesn't have selection.
Thanks in advance.
On 19/06/2017 at 12:34, xxxxxxxx wrote:
I figured it out, apparently I can dynamically add/modify parameters to descriptions at runtime
by overriding GetDDescription() function and using the following steps to hide the desired parameter:
//Get the desired parameter
1-Description::GetParameterI(const DescID &id, AtomArray *ar)
2- BaseContainer::SetBool(DESC_HIDE, true);
On 20/06/2017 at 01:43, xxxxxxxx wrote:
welcome to the Plugin Café forums
I'm glad, you already found the right approach yourself.
A few additional thoughts:
- You can not only hide single widgets, but also for example groups of them.
- Instead of hiding certain widgets, you also have the option of creating widgets only under certain conditions.
On 20/06/2017 at 03:08, xxxxxxxx wrote:
thanks for the additional info, I have already found those pages on the manual yesterday.
On 19/08/2017 at 13:36, xxxxxxxx wrote:
is there an easy possibility to hide an userdata element
in a multi column group with multiple rows,
without messing up the layout?
--> setup 2 columns
--> goal hide B1
--> reality B1 hidden
On 21/08/2017 at 05:59, xxxxxxxx wrote:
one way would be to have three groups with two columns each.
Another option instead of hiding might be to disable parameters.
Would be interesting to know in which context you want to achieve this?
On 21/08/2017 at 11:33, xxxxxxxx wrote:
i made my userdata in the app (not by code) ....
its just a python tag and i wanted to hide an element
setting a group to 2 columns and adding 2 groups inside sadly doesnt give me 2 columns :/
maybe i gotta try to make a real tag plugin
On 21/08/2017 at 11:41, xxxxxxxx wrote:
Sorry, I probably should have explained a bit more in detail.
I thought of something like this (each of the three groups G1 to G3 set to two colums) :
- G1 \+ A1 \+ B1 -G2 \+ A2 \+ B2 - G3 \+ A3 \+ B3