sketchucation logo sketchucation
    • Login
    ℹ️ Licensed Extensions | FredoBatch, ElevationProfile, FredoSketch, LayOps, MatSim and Pic2Shape will require license from Sept 1st More Info

    How make a window like the components window

    Scheduled Pinned Locked Moved Developers' Forum
    5 Posts 3 Posters 344 Views 3 Watching
    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.
    • M Offline
      morci429
      last edited by

      how make a window like the components window as an interface to represent a new class i made called Buildings

      1 Reply Last reply Reply Quote 0
      • thomthomT Offline
        thomthom
        last edited by

        @morci429 said:

        class i made

        New plugin? Or new Dynamic Component?

        The Dynamic Component Properties window is made using the Webdialog class:
        http://code.google.com/apis/sketchup/docs/ourdoc/webdialog.html

        If you've not used that class before it's worth reading this thread: http://forums.sketchucation.com/viewtopic.php?f=180&t=23445

        Thomas Thomassen — SketchUp Monkey & Coding addict
        List of my plugins and link to the CookieWare fund

        1 Reply Last reply Reply Quote 0
        • Dan RathbunD Offline
          Dan Rathbun
          last edited by

          They would have to be Components or DynamicComponents.. as we cannot create custom Drawingelement subclasses. (There are no methods to add custom classes to the model's entites. In addition, none of the manipulation methods accept subclasses. They are hard-coded to test the arguments for specific Sketchup::Drawingelement subclasses, such as Face, Edge, etc.)

          I'm not here much anymore.

          1 Reply Last reply Reply Quote 0
          • M Offline
            morci429
            last edited by

            thanks for the help guys, so far i managed to create a new class called buildings what I’m trying to do is while I’m working on a model of 40 buildings i can then highlight any shape i like and right click on it and set it as a building. Therefore i would have a window like the "Entity info" window which can be displayed from the window menu that would have a drop down menu with a list of the buildings i made so far.
            Does that make any sense? i know it's a bit ambitious but i guess it would help a lot of people

            1 Reply Last reply Reply Quote 0
            • Dan RathbunD Offline
              Dan Rathbun
              last edited by

              Reread my previous post.

              Then readup on Components and Dynamic Components (which are actually Components with special Attribute Dictionaries.)

              What you really need to do is create a Building Component Manager plugin. But the buildings themselves will have to be Components, and/or Dynamic Components (which will likely have a "Building" Attribute Dictionary attached to them, with keys and values that your manager will use to keep track of and organize them.)
              Now.. it IS possible that within your manager namespace, you can have a class Building, whose instances hold a reference (instance variable,) to a Component Instance that is actually in the model.

              The SKP file format has an embedded thumbnail image, which if you have that file in a link in the browser (I'm talking webdialog,) then the thumbnail should display just as if you had any other image filetype on a webpage. It may be possible to drag and drop from the webdialog into the Sketchup client area. (We know we can do this from a folder explorer window.)

              Do a search for other topics on "Warehouse" as others have discussed making a webdialog or website similar to Google's 3DWarehouse. You may pick up some ideas in those threads.

              I'm not here much anymore.

              1 Reply Last reply Reply Quote 0
              • 1 / 1
              • First post
                Last post
              Buy SketchPlus
              Buy SUbD
              Buy WrapR
              Buy eBook
              Buy Modelur
              Buy Vertex Tools
              Buy SketchCuisine
              Buy FormFonts

              Advertisement