Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware API
      • ZBrush Python 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

    BitmapButton in ObjectProperties

    Scheduled Pinned Locked Moved SDK Help
    7 Posts 0 Posters 592 Views
    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.
    • H Offline
      Helper
      last edited by

      THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

      On 26/01/2012 at 08:03, xxxxxxxx wrote:

      User Information:
      Cinema 4D Version:   13 
      Platform:   Windows  ;   Mac OSX  ; 
      Language(s) :     C++  ;   PYTHON  ;

      ---------
      Is it possible to create a UserArea in the ID_OBJECTPROPERTIES group of an object plugin's .res file? Or through the plugin's source directly?
      It works fine with plugins that open dialogs, but I couldn't find anything in the sdk on how to add those areas to property windows...

      1 Reply Last reply Reply Quote 0
      • H Offline
        Helper
        last edited by

        THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

        On 27/01/2012 at 01:16, xxxxxxxx wrote:

        AFAIK you can't add a GeUserArea to descriptions.

        1 Reply Last reply Reply Quote 0
        • H Offline
          Helper
          last edited by

          THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

          On 27/01/2012 at 01:46, xxxxxxxx wrote:

          Hm, that's unfortunate. I was hoping to somehow include some bitmaps in there. I'm sure I've seen something like that in a plugin at some point... though maybe I'm just imagining it.

          1 Reply Last reply Reply Quote 0
          • H Offline
            Helper
            last edited by

            THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

            On 27/01/2012 at 02:09, xxxxxxxx wrote:

            Bitmaps can be added through BitmapButtons to descriptions. Please search the forum for bitmapbutton.

            UserAreas can be used in your own custom GUIs though. These are a bit tricky though.

            cheers,
            Matthias

            1 Reply Last reply Reply Quote 0
            • H Offline
              Helper
              last edited by

              THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

              On 27/01/2012 at 04:20, xxxxxxxx wrote:

              Hi Matthias,
              thanks for the info. Unfortunately it's still not working properly here. I'm mainly using Python, so maybe that's to blame...

              I've included the description in the res and header file (with BORDER set) and, well, the border is visible, but I have not found a way to set the bitmap. The cpp examples all listen for a MSG_DESCRIPTION_GETBITMAP message, which is never being called in my case. So, how do I set the bitmap on the button in Python?

              1 Reply Last reply Reply Quote 0
              • H Offline
                Helper
                last edited by

                THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

                On 27/01/2012 at 07:09, xxxxxxxx wrote:

                Originally posted by xxxxxxxx

                I've included the description in the res and header file (with BORDER set) and, well, the border is visible, but I have not found a way to set the bitmap. The cpp examples all listen for a MSG_DESCRIPTION_GETBITMAP message, which is never being called in my case. So, how do I set the bitmap on the button in Python?

                Using Python, it's not possible to set the bitmap for a custom bitmap GUI in a description with MSG_DESCRIPTION_GETBITMAP message.

                Here's how to do this in a Python plugin:

                First, before you register the plugin, you register the bitmap with a valid ID:

                BITMAP_ID = 100000 # Choose a unique ID!
                ..
                if __name__ == "__main__":
                	..
                	gui.RegisterIcon(BITMAP_ID, bitmap)
                	plugins.Register*Plugin()
                	..
                

                Then, in your res description file declare your BITMAPBUTTON element like this:

                BITMAPBUTTON PLUGIN_BITMAP { BORDER; ICONID1 100000; }
                

                In the res we can only use the bitmap ID literal value (100000), not its ID name (BITMAP_ID).

                1 Reply Last reply Reply Quote 0
                • H Offline
                  Helper
                  last edited by

                  THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

                  On 27/01/2012 at 08:57, xxxxxxxx wrote:

                  Thanks Yannick, that worked -  and not at all like I thought it would 🙂

                  Cheers
                  Michael

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