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

    Existing Toolbar Buttons on a New Toolbar

    Scheduled Pinned Locked Moved Developers' Forum
    4 Posts 3 Posters 317 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.
    • P Offline
      Primate
      last edited by

      Hi. Long time lurker here.

      I'm trying to create a sketchup toolbar that has a couple of new functions on buttons, but I would also like to include some of the buttons from existing toolbars (Primarily Move and Rotate). I'm aware how to create new toolbars and create and link buttons in ruby, but are the functions I'm looking for accessible through the code in any way at all that doesn't require rewriting the main sketchup program? Pre-emptive thanks for any replies, answers or guesses.

      1 Reply Last reply Reply Quote 0
      • T Offline
        todd burch
        last edited by

        Yes. Search on send_action, or just go here: http://download.sketchup.com/sketchuphelp/gsu6_ruby/Docs/Ruby-Sketchup.html#send_action

        Todd

        1 Reply Last reply Reply Quote 0
        • Chris FullmerC Offline
          Chris Fullmer
          last edited by

          Oh Todd! I finally new an answer!, but you beat me to it. But since I looked it up, I'll still put it out there.

          this line:

          Sketchup.send_action("selectMoveTool;")
          

          is all it takes to activate the move tool for example. So make your icon run that code and it will do what you want. Todd already posted the link to all the possibilites.

          Chris

          Lately you've been tan, suspicious for the winter.
          All my Plugins I've written

          1 Reply Last reply Reply Quote 0
          • P Offline
            Primate
            last edited by

            Ah yes, that's perfect, thank you ever so much.

            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