Probably this page is closer what you have in mind.
Posts made by Jim
-
RE: Where is the SketchUp API site?
-
RE: Scale to exact dimension ?
Scale the objects to some arbitrary size, and then enter the exact lengths after. You can now enter " marks without the Scale Tool switching modes.
Are you saying the Mac Scale Tool changes modes after completing the operation?
-
RE: Solid tools on components
@newnoob said:
I suppose you are the Jim who wrote "Trim and Keep", many thanks for that!
Aye. You're welcome. Thank Dave - he's the one who conceived it - I just wrote it.
-
RE: Solid tools on components
@newnoob said:
Thanks Dave, Trim and Keepp is working flawless. I was succesfull in trimming all the strut instances against all the hub instances of my geodesic dome model.
I am glad you were successful too. FYI Trim and Meep purposefully does not remove the components left around after performing the operation. They are all still available in the Component Browser. Run a Purge Unused operation to clean them up.
-
RE: [Plugin] GreyscaleMode
Hinujak,
GreyScale is compatible with 2017 - it is available in the SketchUcation Store. Please let me know if you have any trouble downloading or using.
-
RE: Save and recall parameters of an object created with ruby
Use an AttributeDictionary attached to the wall Component.
You can attach the dictionary to either the ComponentInstance or the ComponentDefinition (or both) depending on your needs. AttributeDictionaries can be attached to any SketchUp Entity or the Model for that matter. AttributeDictionaries are saved with the model on disc.
You use them similar to a Ruby Hash object, but they store the key/values to a SketchUp Entity. Use the
#set_attribute
and#get_attribute
methods of Entity objects. -
RE: ARK II Vehicle
Nice render. It reminded me of this thing:
https://web.archive.org/web/20061205103239/http://www.joeld.net:80/snowcruiser/snowhist.html
-
RE: Any way to install two copies of SU (same version)?
I believe a way to save the toolbar positions and restore them would be ideal, not only for my current situation, but also for Backup/Restore.
It may be possible to backup and restore the registry for various configurations in your batch file.
Export:
reg export "HKCU\Software\Sketchup\SketchUp 2017" Sketchup_2017.reg
Import:
reg import Sketchup_2017.reg
-
RE: Any way to install two copies of SU (same version)?
There are also 2 settings available through the Sketchup module that may be of interest.
They are plugins_disabled and debug_mode.
-
RE: Any way to install two copies of SU (same version)?
I don't care for the idea of renaming the folder although it's probably fine.
First just set an environmental variable from the batch file, and use it in a Ruby script to select a plugins sub-folder to load from.
Second, SketchUp accepts a command line argument which is a Ruby script to run. It can be located anywhere. Search this forum for RubyStartup.
I have a GutHub repo with and example of portable plugins loading. https://github.com/jimfoltz/SketchUp-Portable-Plugins-Loader
-
RE: View.write_image shows dotted line border
@rami_lpm said:
the color can be adjusted? is there a command to do that? I can try and see.
I think it is one of the RenderingOptions.
-
RE: Changing the component name in Components Directory.
It would not be hard to script, it's "only" a matter if finding someone with time. I can look into it later this week if no one else comes along.
-
RE: How do I correctly set the Length formulas in a DC via Ruby
It looks like you need to do this:
comp1_def.definition.set_attribute(@component_dictionary, '_lenx_formula', (laenge.to_f*2.54).to_s)
But you will need select the conversion factor based on the DC Dialog units. It will either br cm or inches.
-
RE: How do I correctly set the Length formulas in a DC via Ruby
What is the value you are using to set the attribute? Print it out to the Ruby Console using the
p
command.From the image,it could be incorrect decimal separator.
Or you are including the "=" in the formula.
Or try not incuding the units in the forumula.
There are "=" sign in the taxt box but the "Toggle Formula View" is not pressed. The "=" should not be there.
-
RE: How do I correctly set the Length formulas in a DC via Ruby
Not this:
comp1_def.definition.set_attribute @Component_dictionary,'lenx', '_lenx_formula'
Correct:
comp1_def.definition.set_attribute(@Component_dictionary, '_leny_formula', '2*LenX')
Please provide minimal but complete and executable code when asking for help. This means properly indented, properly namespaced, with a menu item, and no Syntax Errors. You will get better help. Also, either attach the .rb file or wrap the posted code in
[code][/code]
tags.
-
RE: Dynamic components for folding table base
I had the right idea using the sin function but I had to shift the movement 90 degrees out of phase. This one should work and look more natural, even if it is not perfect.
-
RE: Dynamic components for folding table base
I also tried to fix the animation so the parts don't go through one another. I thought using the sin function would do it but I must not have had the formula just right. I do think it can be done I just ran out of time.