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

    [Plugin] Boolean helper update 08122011

    Scheduled Pinned Locked Moved Plugins
    77 Posts 15 Posters 38.2k Views 15 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.
    • liquid98L Offline
      liquid98
      last edited by

      Hi TIG,

      @tig said:

      I don't see the problem ? On the rare occasions when the user has deleted the entire model [and why would they do that?] the scaling becomes irrelevant anyway, so they can just delete it ?

      I admit, that situation won't occur very often. But I only want to tackle it to learn new stuff... 😛

      When I put your code in a .rb file, like this:

      <span class="syntaxdefault">    require </span><span class="syntaxstring">'sketchup.rb'<br /><br /></span><span class="syntaxdefault">    class OnlyScreenTextLeftEntitiesObserver </span><span class="syntaxkeyword"><</span><span class="syntaxdefault"> Sketchup</span><span class="syntaxkeyword">;;</span><span class="syntaxdefault">EntitiesObserver<br />      def onEraseEntities</span><span class="syntaxkeyword">(</span><span class="syntaxdefault">entities</span><span class="syntaxkeyword">)<br /></span><span class="syntaxdefault">    UI</span><span class="syntaxkeyword">.</span><span class="syntaxdefault">messagebox </span><span class="syntaxstring">"OK"<br /></span><span class="syntaxdefault">     end<br />    end<br />  <br />   <br />    Sketchup</span><span class="syntaxkeyword">.</span><span class="syntaxdefault">active_model</span><span class="syntaxkeyword">.</span><span class="syntaxdefault">entities</span><span class="syntaxkeyword">.</span><span class="syntaxdefault">add_observer</span><span class="syntaxkeyword">(</span><span class="syntaxdefault">OnlyScreenTextLeftEntitiesObserver</span><span class="syntaxkeyword">.new)</span><span class="syntaxdefault"> </span>
      

      and then start sketchup, create some entities and delete them,

      Nothing happens... Why??

      Things that flourish fall into decay. This is not-Tao, And what is not-Tao soon ends ~ Lao tse

      1 Reply Last reply Reply Quote 0
      • TIGT Offline
        TIG Moderator
        last edited by

        Well if it did work every time you erased something you'd get the messagebox...
        The EntitesObserver is known to be buggy... if we did get it to work and erased an entity within it it'd probably crash anyway - so my snippet probably wasn't the best idea 😒
        How about using a selectionObserver...onBulkChange() - you select the things and then erase them and the selection changes... and then looking at model.entities if no [1] and [0] meets test erase it ...
        http://code.google.com/apis/sketchup/docs/ourdoc/selectionobserver.html

        TIG

        1 Reply Last reply Reply Quote 0
        • liquid98L Offline
          liquid98
          last edited by

          I updated the booleanhelper plugin! Please see the first post of this topic.

          Things that flourish fall into decay. This is not-Tao, And what is not-Tao soon ends ~ Lao tse

          1 Reply Last reply Reply Quote 0
          • D Offline
            driven
            last edited by

            hi,

            I believe I just exposed a bug, doing another testhttp://forums.sketchucation.com/viewtopic.php?f=180&t=38858&p=354541#p354541

            when I have 'auto paint tool' Mac preference set, your twee tekst and LEEEEEG message boxes pop up every time I select or delete something even though I wasn't using your tool.

            appears to be "Sketchup::SelectionObserver" related.

            I'd rather use this then that, but I'd like the option of both...

            cheers

            john

            learn from the mistakes of others, you may not live long enough to make them all yourself...

            1 Reply Last reply Reply Quote 0
            • liquid98L Offline
              liquid98
              last edited by

              Hi John,

              Just download and install latest version -see first post of this topic.

              Good luck!

              Things that flourish fall into decay. This is not-Tao, And what is not-Tao soon ends ~ Lao tse

              1 Reply Last reply Reply Quote 0
              • D Offline
                driven
                last edited by

                cheers,
                I'll let you know if I have any issues,,,

                john

                learn from the mistakes of others, you may not live long enough to make them all yourself...

                1 Reply Last reply Reply Quote 0
                • C Offline
                  CT4
                  last edited by

                  Thank you Thank you Thank you. I model small parts for RC aircraft and run into so many problems when I try and lathe them or intersect them. This fixes all of the problems.

                  1 Reply Last reply Reply Quote 0
                  • liquid98L Offline
                    liquid98
                    last edited by

                    It's always nice to hear that my script helped you out! Apparently it works also on a Mac; never tested it 🎉 🎉

                    Things that flourish fall into decay. This is not-Tao, And what is not-Tao soon ends ~ Lao tse

                    1 Reply Last reply Reply Quote 0
                    • cottyC Offline
                      cotty
                      last edited by

                      Thank you for this helpful plugin!

                      my SketchUp gallery

                      1 Reply Last reply Reply Quote 0
                      • S Offline
                        sboup
                        last edited by

                        @liquid98 said:

                        This is my modest contribution to the community:

                        Booleanhelper

                        The Boooleanhelper plug-in lets you quickly scale up and down your model.
                        This is especially useful for those people who use Sketchup for 3d printing.
                        Performing boolean operations or lathe operations on small models (mm size) is problematic in Sketchup, because Sketchup doesn't handle small faces very well.
                        By scaling up the model these problems disappear. After all operations are done
                        you can scale down your model to its original dimensions.
                        Also useful to close small holes in your model.

                        Your opinions and suggestions are welcome!

                        Features:

                        • Visual feedback on scale-factor.
                        • Scale down at once.
                        • It is possible to save your work, and scale down later. (feedback not yet provided)
                        • Auto zoom extents.

                        Installation:
                        Open the zipfile and copy booleanhelper.rb and the folder called Booleanhelper into the SU plugins directory.

                        Have fun!!

                        If you have problems with unsolicited messageboxes, please download the latest version below:

                        Wonderfull. Thanks ☀

                        1 Reply Last reply Reply Quote 0
                        • A Offline
                          Aggertroll
                          last edited by

                          I love this script - does exactly what it is supposed to (on my Mac) and lets me design small parts for 3D print in a larger scale. Very helpful - thanks!

                          I have one small comment/request: I am using Fredo6's "!Additional.Pluginfolders" plugin to sync my plugins via dropbox across my different machines - great help by the way. I noticed that the icon in the toolbar will not show for the Boolean helper if that plugin resides in my plugin folder on dropbox; it must be looking for the icon in the standard plugin folder. Is there a way to fix that? As in "Get the image from the folder Booleanhelper in the same folder that this script is in" - if that makes sense?

                          There are of course simple ways to fix this - install Booleanhelper on all machines - but the fix would remove a glitch when using a custom plugin folder. Thank you for your efforts!

                          1 Reply Last reply Reply Quote 0
                          • D Offline
                            driven
                            last edited by

                            @aggertroll said:

                            There are of course simple ways to fix this...

                            change line 296 in a plain text editor, and re-save...

                                    plugins = Sketchup.find_support_file("Plugins")
                            

                            to

                                  plugins = File.dirname(__FILE__)
                            

                            john

                            learn from the mistakes of others, you may not live long enough to make them all yourself...

                            1 Reply Last reply Reply Quote 0
                            • A Offline
                              Aggertroll
                              last edited by

                              John: Thanks a bunch. Works!

                              1 Reply Last reply Reply Quote 0
                              • B Offline
                                Boff
                                last edited by

                                Hi, I don't know if this plugin is still being worked on but I'm unable to scale down a model after saving it.

                                The message I get is "Scale up your model first, and then use the 'Scale down at once' button"

                                Using SU2016 if that makes a difference.

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

                                Advertisement