⚠️ Important | Libfredo 15.6b introduces important bugfixes for Fredo's Extensions Update
  • Add a group to another group by rupy-code

    3
    0 評價
    3 貼文
    283 瀏覽
    thomthomT
    @andreas said: Hi, I would like to insert "Group1" into "Group2" by ruby-code. What should I do to make this work? Are you talking about existing groups? If so, refer to TIGs post. If you are creating new groups via Ruby: group1 = model.active_entities.add_group group2 = group1.entities.add_group
  • Save Toolbar Positions

    2
    0 評價
    2 貼文
    317 瀏覽
    thomthomT
    When I last looked at the registry it appeared that the function was simply making a second set of registry keys. Originally you got lots of ToolbarsUser-Bar0 ToolbarsUser-Bar1 ToolbarsUser-Bar2 ... When you use SU8's Save Position you get an extra set: ToolbarsUserCustom-Bar0 ToolbarsUserCustom-Bar1 ToolbarsUserCustom-Bar2 ... So it's no easier to control their positions now, than what it was before.
  • Quick and easy ruby script?

    2
    0 評價
    2 貼文
    351 瀏覽
    P
    so if i understand correct you want a file with on each line: groupname1-location1 groupname2-location2 ? If so I think you need to: loop all SU entities check if entity is group if so: get the name get the location info store those in a array [[name,location],[name,location],[name,location]] or hash end of loop then put the array in a file with File.open Something like that i think
  • Does SketchUp delete empty groups?

    2
    0 評價
    2 貼文
    390 瀏覽
    thomthomT
    Yea - SU tries to clean up some times. If you for instance erase all the entities in a ComponentDefinition that definition will disappear. (Though I'm not exactly sure when SU does that.) Could you place a CPoint in it?
  • Sphere Create Ruby

    4
    0 評價
    4 貼文
    526 瀏覽
    thomthomT
    cheers!
  • Geosphere?

    15
    0 評價
    15 貼文
    990 瀏覽
    AdamBA
    There you go. http://forums.sketchucation.com/viewtopic.php?f=180&t=30694&p=269864#p269864
  • Check which plugins are enabled in Preferences->Extensions

    2
    0 評價
    2 貼文
    230 瀏覽
    thomthomT
    Sketchup.read_default Does appear to be limited, it won't read any Windows settings, nor SketchUp settings.
  • WebDialog - execute_script outside of add_action_callback?

    6
    0 評價
    6 貼文
    597 瀏覽
    thomthomT
    Another tip which I might not have mentioned in that article, I find using a javascript framework (like jQuery) takes the pain out of the cross-compatibility JS issues.
  • No Syntax Errors on Loading?

    9
    0 評價
    9 貼文
    663 瀏覽
    Dan RathbunD
    @jim said: I don't know, what happens? (because I'm not sure how to go about doing that.) here is a simple file that should load before all others: call it !!!aaa.rb # # file; !!!aaa.rb # # A snippet from my !loadpaths.rb - by Dan Rathbun # skp_info=true ruby_info=true load_paths=true global_vars=false # delay=0.5 # Sketchup.send_action("showRubyPanel;") UI.start_timer(delay,false) { puts "\n" puts '----------------------------------------------------'<<"\n" if skp_info # print Sketchup Info to console puts ' Sketchup has been Loaded...'<<"\n" puts ' Sketchup Version ; '<<"#{Sketchup.version}\n" puts '----------------------------------------------------'<<"\n" end if ruby_info # print Ruby Info to console puts ' RUBY has been Loaded...'<<"\n" puts ' RUBY_PLATFORM ; '<<"#{RUBY_PLATFORM}\n" puts ' RUBY_VERSION ; '<<"#{RUBY_VERSION}" puts ' RUBY_PATCHLEVEL ; '<<"#{RUBY_PATCHLEVEL}" puts ' RUBY_RELEASE_DATE ; '<<"#{RUBY_RELEASE_DATE}" puts ' RUBY_COPYRIGHT ; '<<"#{RUBY_COPYRIGHT}\n" puts '----------------------------------------------------'<<"\n" end # ruby_info if load_paths # print LOAD PATHS to console puts "\n LOAD PATHS ($LOAD_PATH | aka $;) array;\n" $LOAD_PATH.each {|x| puts " #{x}\n"} puts '----------------------------------------------------'<<"\n" end # load_paths if global_vars # print Global variables to console puts ' RUBY Global variables;'<<"\n" puts '----------------------------------------------------'<<"\n" global_variables.each {|x| puts " #{x} = "<<eval("#{x}.inspect"<<"\n")} end # global_vars puts '----------------------------------------------------'<<"\n\n" } #
  • What DHTML does WebDialog support?

    2
    0 評價
    2 貼文
    221 瀏覽
    thomthomT
    On Windows the webdialog uses the Internet Explorer version that is installed on the user's computer. On OSX it's webkit. The webdialog isn't a limited sub-set, but make use of that the OS has available.
  • Question about pages

    6
    0 評價
    6 貼文
    388 瀏覽
    thomthomT
    @jim said: By the way, what is the difference between a page .name and a page .label? Seem to be the same, except label doesn't have a setter... The examples for the getters are pretty much the same.
  • Reset colourized texture?

    2
    0 評價
    2 貼文
    244 瀏覽
    thomthomT
    I love answering my own questions... http://code.google.com/apis/sketchup/docs/ourdoc/material.html#color= @unknownuser said: To reset the color of a Material with a Texture, set the color to nil.
  • Instructor

    2
    0 評價
    2 貼文
    351 瀏覽
    thomthomT
    Plugins that makes use of the Tool class to make custom tools can implement an Instructor help page: http://code.google.com/apis/sketchup/docs/ourdoc/tool.html#getInstructorContentDirectory
  • SketchUp 8 Observers crash

    2
    0 評價
    2 貼文
    368 瀏覽
    thomthomT
    Also reported here: http://forums.sketchucation.com/viewtopic.php?f=180&t=20676&start=15#p268315 Have you used InstanceObserver before SU8? I could never get it working - no events ever triggered...
  • SketchUp Command Line: RubyStartup

    19
    0 評價
    19 貼文
    12k 瀏覽
    J
    After that video, I went looking and found a few: -template "/path/to/template.skp" # startup template -notemplate # use no template -page "Scene 1" # set the staring scene -timing # some sort of test? There's more, if you search the .exe for these strings.
  • LargeToolSet toggle ruby

    4
    0 評價
    4 貼文
    324 瀏覽
    J
    @thomthom said: How on earth did you find that? The unix strings command. I tripped over while looking for command-line options.
  • Module.foobar vs Module::foobar ?

    12
    0 評價
    12 貼文
    869 瀏覽
    Dan RathbunD
    @jd hill said: ..., for which jessejames's above statement is an alias. LOL ~
  • Skin.rb Files

    18
    0 評價
    18 貼文
    9k 瀏覽
    A
    Men... this is completely awesome!!! ver 2.2 works perfect... but in a non developer language, what will clean do? again, THANK U VERY MUCH!
  • Ruby to rotate overhead view 90 degrees around blue axis?

    9
    0 評價
    9 貼文
    4k 瀏覽
    DavidBoulderD
    You can also take an object oriented the way you want your plan, and create a new axis using that object. For your new axis blue is still on the Z axis for your model, set the green axis to go in the direction that you want to be at the top of your screen in plan view. You can save this as a scene and always jump back to it.
  • SketchUp::Image transforms

    8
    0 評價
    8 貼文
    448 瀏覽
    thomthomT
    I do like that approach though. Using Images for advanced material compositing.

Advertisement