Beluga: I looked at the ruby code site and it seems all no's are stored in inches in SU even if you use a metric template. I would need to work on that if it was a desired option.
Keith
Beluga: I looked at the ruby code site and it seems all no's are stored in inches in SU even if you use a metric template. I would need to work on that if it was a desired option.
Keith
Dave there are changes since I sent it to you. I actually found that it did not load except thru the ruby console. I revised the menu then as I worked on dowels I needed to enter fractions so I worked on the input form to accept fractions and equations along with numbers.
I am very new to the video stuff and tried to convert it to a flash file but it is very hard to see. I did zip the file and got it down to 17mb so I will post that.
This file uploaded in 3min and my net is not very fast.
http://www.adrive.com/public/1c49c6720f7232d46c55ef831de38f985d75d3be04f453b3ead4989ded26f616.html
Keith
Here is link to an avi file that demos making a Mortise & Tenon Joint.
ADrive provides online cloud storage and backup solutions for personal, business and enterprise-level data. Manage, edit and share your data online with ADrive.
(www.adrive.com)
Hope this helps in using the tool.
Keith
This is a revised version of my MortiseTool. The original was included in Woodwrk2 & based on his Dado Tool with help from the fantastic members of the SU Forum. The new program makes a complete joint from the data entered in the form to define the tenon dimensions.
Features:
Creates complete joints for Mortise & Tenon Joints or Both Mortises for Loose Tenon Joints.
Also will draw a single Tenon or Mortise.
Tenons or Mortises can have Square or Round Ends.
Also will draw Haunched Tenons and the corresponding mortise.
Will draw dowel holes for doweled joint. Use LT_Mortise and select "Dowel" for End Shape.
Mortise depth in second part is specified separate so it can be different than the Tenon Length.
Tool is added to the "Draw" menu with pullouts to the individual tools.
Input Form will accept numbers, fractions, or equations.
The SU file shows how the dim correspond to the data form and provides sample joints to practice on. Remember that "Ctrl Z" will undo so you can also reuse the same parts over. I have also shown a couple of examples to use the program for dado and spline joints.
The zip file contains: KK_MortiseTool.rb; KK_MortiseTool.txt; KK_MortiseToolDim.skp; and MortiseTool.rb; (This is included for the users of woodwrk2 which has my first version)
Keith
I finally got the code to work using part of the code from Fredo. The problem was that some entries were interpreted as strings. After I added a final to_f then the program worked as I wanted. I am going to post the KK_MortiseTool.rb here so you can look at that to see how I worked that out.
Thanks to all for their help and reply's.
Keith
I have been doing some testing and I find I can open the win cal while the data form is up and waiting for input so any dim that needs some calculation to make the proper entry can be calculated and using a copy/paste input into the form. Since I program mostly for my own use (but offer to other woodworkers) I am going to leave it there for now. With a little more testing I will zip up the files and post it here.
Thanks for all the help
Keith
I am trying to understand modules. Documentation seems sparse. I remember in VB6 you included them at a specific part of the code and then they were always available.
The example from the Automatic Sketchup Book:
require "Ch8/mods.rb"
require "Ch8/house3.rb"
# Create a subclass of House
class New_House < House
# Add the capabilities from Module A
include Module_A
def test_method
draw
print_hello
print_goodbye
end
end
This is how I used it here. Then after the input box @@todist=ArithmeString.string_to_float_formula(results[0]) and as I said it works just fine the first time but not after that. Each time I load the mortisetool.rb which requires Arithmetic parsing.rb the equation is evaluated the first time thru the tool class.
Thanks
Keith
Fredo: Thanks for the code. I used as written and added a require Arithmetic parsing.rb and then added include ArithmeString inside my class MortiseTool. This almost works!!! GOOD NEWS. After loading the file the first time accessed the input form accepts an equation and makes the calculation. Now comes the BAD NEWS any time after that I get an error that the equation is improper input. I read in the SU Ruby book about modules but obviously I don't quite know the proper usage. My input box is coded within the def onLButtonDown(flags, x, y, view) part of my class. How do I get the module to be available each time thru the code where the input box is specified?
Keith
Has anyone developed a method to allow the user to enter an equation into a input form field?
I have rewritten my mortisetool.rb and sometimes when the input form is presented I need to make a calculation to determine the proper dimension to enter. The program accepts input thru the inputbox.
Using win7 I can pop up the calculator and make the calculation then copy paste into the form but would be much more convenient to enter the equation in the form and have the program evaluate and use the answer. From my tests entering anything but a number results in an error and halts the program.
Keith
I have been revising my mortisetool.rb file and the new version loads fine with no errors listed using the ruby console. However when I place it in the plugin folder I get this error message on loading.
Error Loading File KK_MortiseTool.rb
undefined method `GetString' for nil:NilClass
I have set variables to nil initially so I can test to see if the program has changed them.
I used this method also in the original version and had no trouble loading it.
Possible solutions?
Thanks
Keith
I have a point in a component's local axis and want to transform this into a second component's local axis.
My thinking is that I would need to transform this from the first local axis to the global axis and then from the global to the second local axis. I looked at the component instance class but could not decide how to use the transformation functions to do this.
Keith
Sorry my script was not what you needed. This topic started with the boardmaker plugin that makes a component but you must be using a different plugin to draw the board as you are making the board a group.
So you have a list of names that you know ahead of time and want to create a board by entering dimensions and then selecting the name from a list and place it on a layer of the same name? Am I understanding what you are attempting to accomplish?
I am curious why use groups instead of the components most of us use?
Do you have a perffered orientation for the panel?
It seems to me that all the parts for a script that does what you are asking have been written but they just need to be combined and tweeked for your process. But we would need to know your exact workflow to see what would be involved.
Keith
Here is a plugin I wrote that allows you to rename the board and places it on a layer of the same name. To use right click on the board component after it is made and select board to layer from the context menu.
KeithBoardToLayer.rb
Dave: Don't miss the whole point of the post as an easier method of transfering the mating joint detail to the next part. This is so much simpler than your post of viewing the joint from inside the part and outling the joint to transfer the position. I know you don't separate into layers as much as I am doing but that has nothing really to do with the main concept of the post.
Keith
I am not talking about changing the active layer but the visibility layer. I always leave layer0 the active layer. I use the layer visibility for ease of separating views and seeing only the parts I want to see in place of using the hide feature.
Keith
I found a new way to transfer M&T detail to the mating part. For example if you have a leg and a Horizontal Strecher with a M&T joint construction.
Keith
Try this plugin it makes a board and makes it a component (which is more useful than a group) and places it on a new layer named from the component. It is very useful to have components on separate layers.
Keith
There is board plugin and I wrote a plugin that makes it a component. Search for board plugin
K2
What files besides the plugin directory would I need to copy to a second computer so Sketcup would work the same. Toobars in the same place, same shortcuts, template etc.
Keith
Check this out: It starts from a component but does allow you to name a layer from the component name and places that component on that new layer.