GetDDescription and multiple column elements



  • On 20/04/2018 at 01:08, xxxxxxxx wrote:

    User Information:
    Cinema 4D Version:   R17 
    Platform:    Mac  ;  
    Language(s) :     C++  ;

    ---------
    Greetings to all.

    I'm trying to build a plugin UI via GetDDescription(). Everything is working fine, except I've encountered an issue where I need to "stretch" a single element horizontally so it takes up more than one column in a multi-column group.

    In a *.res file, I'd just use STATICTEXT { JOINENDSCALE; } to achieve what I want.

    However, I can't seem to find an equivalent for this in the C++ API. There's DESC_NEWLINE, but this doesn't seem to do the same thing as JOINENDSCALE. It will take up a column, but then the widget before it won't stretch out horizontally.

    How can I achieve the same effect as JOINENDSCALE in C++?

    Cheers,
    -CMPX



  • On 20/04/2018 at 06:59, xxxxxxxx wrote:

    did you try to add a static text desc in C++?



  • On 20/04/2018 at 08:57, xxxxxxxx wrote:

    Yeah, it just treats it like an empty space and the widget to the left remains unchanged.

    -CMPX



  • On 20/04/2018 at 09:14, xxxxxxxx wrote:

    not sure if this will work or not...

      
    #define STATIC_TEXT_JOINT_END_SCALE 2403
    

    and in your BaseContainer of the static text desc:

      
    bc.SetBool(STATIC_TEXT_JOINT_END_SCALE , 1); 
    


  • On 20/04/2018 at 21:08, xxxxxxxx wrote:

    Hey, that works great. Dunno why this isn't in the SDK, but it does exactly what JOINENDSCALE does in the *.res files.

    Thanks!

    -CMPX



  • On 23/04/2018 at 02:03, xxxxxxxx wrote:

    Hi CMPX and Mohamed,

    I confirm the use of 2403 is the way to go, and produce the exact same thing as JOINENDSCALE does in the res file.
    I will check why this ID is not exposed, and if there are no relevant stopper, this ID will be added to the documentation.

    Cheers,
    Maxime


Log in to reply