Enable SketchUp tools
-
Hello everyone.
Which code can be used to activate the SketchUp selection tool?
Is there a list that gives all the codes to activate any tools in SketchUp?
Thank you
David
-
http://ruby.sketchup.com/Sketchup.html#send_action-class_method
Sketchup.send_action("selectSelectionTool:")
-
model = Sketchup.active_model tool = model.select_tool(nil)
Class: Sketchup::Model
This is the interface to a SketchUp model.
SketchUp Ruby API Documentation (ruby.sketchup.com)
@unknownuser said:
The select tool is activated if you pass
nil
to theselect_tool
method.
See this thread as well:
https://sketchucation.com/forums/viewtopic.php?t=34840
For SketchUp versions 2016+ they added new methods for window selection that can be used when writing your own Ruby tools:
Class: Sketchup::PickHelper
The Sketchup::PickHelper class is used to pick entities that reside under the current cursor location, similar to native Select tool.
SketchUp Ruby API Documentation (ruby.sketchup.com)
-
@TIG The url feature is seriously scrwed!
-
I have also just noticed this.
If you edit a post with a url it becomes messed up.
I fixed your post's.
But if you were to edit again it'll break them.
I'll get Gábor on to it... -
Thank you for these solutions.
Advertisement