Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware API
      • ZBrush GoZ API
      • Code Examples on Github
    • Forum
    • Downloads
    • Support
      • Support Procedures
      • Registered Developer Program
      • Plugin IDs
      • Contact Us
    • Unread
    • Recent
    • Tags
    • Users
    • Login

    Show/Hide Tabs in GUI

    Cinema 4D SDK
    python
    2
    3
    521
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • N
      neon
      last edited by

      Hello PluginCafe,
      I wanted toknow whether it is possible to show/hide tabs in the GUI (like the Fields tab in the VertexMap) if the Tabs / Groups have been defined in the resource file. Or do I have to add/remove them dynamically through description handling?

      Best Regards,
      Florian

      1 Reply Last reply Reply Quote 0
      • S
        s_bach
        last edited by

        Hello,

        as always, please use the Q&A system to mark your post as a question.

        do you mean with GUI the parameter description of a NodeData based plugin?

        You can only hide description elements through "description handling". So in your plugin, you must implement GetDDescription().

        • NodeData.GetDDescription
        • NodeData::GetDDescription() Manual

        You can load the description defined in the *.res file using Description.LoadDescription().

        • Description Manual

        Then you can edit that description e.g. hide some parameter or some group. You access an existing parameter description using Description.GetParameterI().

        • Description Manual - Edit

        To hide an element, you have to set the setting DESC_HIDE.

        • Description Settings Manual - Visibility

        This example hides the ID_BASELIST_ICON_SETTINGS_GROUP group from the description:

        def GetDDescription(self, node, description, flags):
        
            if not description.LoadDescription(node.GetType()):
                return False
        
            descID = c4d.DescID(c4d.DescLevel(c4d.ID_BASELIST_ICON_SETTINGS_GROUP, c4d.DTYPE_GROUP, 0))
            db = description.GetParameterI(descID)
            db.SetBool(c4d.DESC_HIDE, True)
        
            return True, flags | c4d.DESCFLAGS_DESC_LOADED
        

        best wishes,
        Sebastian

        MAXON SDK Specialist

        Development Blog, MAXON Registered Developer

        1 Reply Last reply Reply Quote 0
        • N
          neon
          last edited by

          Hello Sebastian,
          sorry, for not using the QA System, will do in the future!

          This was exactly what I needed. I have never changed my GUI outside the res file and it felt kinda confusing to me what exactly I have to do after reading the doc.

          Thanks for your awnser!

          Best Regards,
          Florian

          1 Reply Last reply Reply Quote 0
          • First post
            Last post