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
    • Categories
      • Overview
      • News & Information
      • Cinema 4D SDK Support
      • Cineware SDK Support
      • ZBrush 4D SDK Support
      • Bugs
      • General Talk
    • Unread
    • Recent
    • Tags
    • Users
    • Login

    Insert Button for Plugin into standard palette

    Cinema 4D SDK
    python r20 windows
    3
    4
    719
    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.
    • B
      Boony2000
      last edited by

      Hi!

      Is it possible to have a command plugin insert an icon/button into the standard palette on startup?

      I am aware that changing layouts would be something I would have to deal with seperately, but is it generally possible to do what you would normally do via the 'customize commands' menu from within the plugin code?

      Thanks!

      1 Reply Last reply Reply Quote 0
      • ferdinandF
        ferdinand
        last edited by ferdinand

        Hi,

        no, that is not possible. I do not think that this is even possible in C++ (but I might be wrong here). But you can modify the main menu via listening for C4DPL_BUILDMENU in PluginMessage()[1]. There you could add a sub menu that provides a custom new palette that the user can pop out. The problem is: You cannot even read out the current pallets, so you could really only provide a modified standard pallete.

        Cheers
        zipit

        [1] See Enhancing the Main Menu. In Plugin Structure. url: https://developers.maxon.net/docs/py/2023_2/misc/pluginstructure.html?highlight=pluginmessage#PluginMessage

        MAXON SDK Specialist
        developers.maxon.net

        1 Reply Last reply Reply Quote 1
        • M
          m_adam
          last edited by

          Hi @Boony2000, unfortunately as @zipit said, it's not possible to do.

          Another way to do it is to have a custom layout and load it with LoadFile. But it will load the whole palette.

          Cheers,
          Maxime.

          MAXON SDK Specialist

          Development Blog, MAXON Registered Developer

          1 Reply Last reply Reply Quote 0
          • B
            Boony2000
            last edited by Boony2000

            Thanks for the input!
            It's a shame you can't fiddle with the palettes. I think I'll just do it like x-particles and have a command that loads the palette and the user can dock it himself. Not the most elegant, but gets the job done.

            Cheers

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