sketchucation logo sketchucation
    • Login
    1. Home
    2. CadFather
    3. Topics
    ℹ️ Licensed Extensions | FredoBatch, ElevationProfile, FredoSketch, LayOps, MatSim and Pic2Shape will require license from Sept 1st More Info
    Offline
    • Profile
    • Following 0
    • Followers 0
    • Topics 91
    • Posts 1,048
    • Groups 2

    Topics

    • CadFatherC

      JHS Standard 2017

      Watching Ignoring Scheduled Pinned Locked Moved Plugins
      9
      0 Votes
      9 Posts
      3k Views
      Dave RD
      @designerbursa said: PLEASE UPDATE 2021 VERSION I just installed it in SU2022 and it works fine in that version. No reason to expect it wouldn't in SU2021.
    • CadFatherC

      JHS STANDARD 2015

      Watching Ignoring Scheduled Pinned Locked Moved Plugins
      16
      0 Votes
      16 Posts
      3k Views
      CadFatherC
      mmm.. don't think i can do that with ruby - unless the toolbar is moved to a webdialog. it's something i have done but has its problems like stealing focus from keyboard shortcuts. not sure about multiple monitors, but one thing i can suggest for now is to have a look at this little gem called winsize http://sourceforge.net/projects/winsize2/. you can store windows positions using their name.
    • CadFatherC

      Import image (in padded cell..!)

      Watching Ignoring Scheduled Pinned Locked Moved Developers' Forum
      16
      0 Votes
      16 Posts
      641 Views
      Dan RathbunD
      @tig said: I assumed that if you stop a timer it's the same as ' break' in a block, so then it'd never get to image.erase!, but having tested it I see that it complete the entire iteration after the timer is stopped ! Of course it does. A timer just loops and calls the block on the set interval. (The setInterval timers in Javascript work the same way.) This why you should always stop the timer immediately when the condition is met. Otherwise the block gets queued up to be executed again, perhaps even before the first time is done doing it's work. @tig said: I don't immediately see the advantage of using @tid over tid - the block of code executed by the timer is referring back to itself, ... Sometimes it works. But I have experienced that in some situations, the ID reference becomes invalid (perhaps gets garbage collected.) And then the call to stop the timer does not work. [I remember having a discussion with Jim Foltz about timer IDs being invalid, or garbage collected.] The Ruby docs say a proc is supposed to have access to it's environment (like a snapshot,) when it is defined. But the API UI timer is implemented on the C++ side. @tig said: ... it's not like we are stopping it in another def method ? I always assume code samples are going to run in a method. It is rare that code is something that runs once at startup, (although we sometimes do post code like that.) THIS feature we are discussing, is something that will be used "on demand" (by a end user,) in a Tool class or a UI::Command, which means it'll likely be wrapped in a method. Bottom line, ... the above is my best advice on best practice. Believe or not, as you will. It is not arbitrary. I have had timer use fail in the past when using local var for the id. Perhaps under Ruby 2.0, things have changed with regard to the timer IDs, .. but I still always use a persistent reference for timer IDs on the Ruby side, until I know it is no longer needed. As far as using rescue in modifier position goes, that is a no brainer. (And is not a best practice rule I made up. I got it from one of the Style Guides or maybe the "Pick-Axe" book.) begin; statement; rescue; end is just plain uglier, and doesn't read as nice as: statement rescue nil
    • CadFatherC

      Delete all layers via ruby

      Watching Ignoring Scheduled Pinned Locked Moved Developers' Forum
      6
      0 Votes
      6 Posts
      580 Views
      TIGT
      Yes everything. All entities in all entities-collections.
    • CadFatherC

      Drawing with GL

      Watching Ignoring Scheduled Pinned Locked Moved Developers' Forum
      24
      0 Votes
      24 Posts
      869 Views
      CadFatherC
      thanks John, already did that though (screenshot above is a watermark). the problem with this system is that you are forcing a new style on the user: if the user has a sketchy style on, you cannot have the bars and keep the sketchy style. (in other words we cannot load watermarks without loading a style as well). that's why i mentioned about another route: find user current style > save it as variable > load the 'grid' style > restore user style from variable when finished. alas, no way to get the previous style back in. whether from the 'in model' style, or trying to save it to a temp directory and loading it back from there. (at least i found no info at all anywhere). PS least of all the api docs!
    • CadFatherC

      Power Toolbar (2.5) - fix for 2019

      Watching Ignoring Scheduled Pinned Locked Moved Plugins
      78
      0 Votes
      78 Posts
      114k Views
      CadFatherC
      Hi, unfortunately i don't have a mac on which to test the bugs. if any mac using author wants to have a look, that's fine. time is a bit tight, but hope to update JHSPB sometime in late february if i can. meantime, i just thought that you can edit manually the toolbar file: "jhs_pb_settings.txt" true means the icon will show, false it is hidden. if you reference the list with the image below, you can make it easier to see which icons will checked (true) or not (false). [image: L0tA_ICONSV2.2.jpg]
    • CadFatherC

      Check "if view?"

      Watching Ignoring Scheduled Pinned Locked Moved Plugins
      7
      0 Votes
      7 Posts
      250 Views
      jiminy-billy-bobJ
      Indeed much nicer way to do it, jim
    • CadFatherC

      Key combinations

      Watching Ignoring Scheduled Pinned Locked Moved Developers' Forum
      5
      0 Votes
      5 Posts
      346 Views
      S
      @cadfather said: Thanks Guys, i'll have a look at Jan's table. can't believe it's so messy working with the keyboard. Yes, messy - but the mess originates in the OS, not SketchUp!
    • CadFatherC

      Select all comps if contain name

      Watching Ignoring Scheduled Pinned Locked Moved Plugins
      5
      0 Votes
      5 Posts
      226 Views
      CadFatherC
      brilliant, does more than i asked! need to study it a bit now (tax return can wait...) Thanks
    • CadFatherC

      OnKey_Downer!

      Watching Ignoring Scheduled Pinned Locked Moved Developers' Forum
      7
      0 Votes
      7 Posts
      429 Views
      CadFatherC
      i guess one workaround is to make a webdialog tiny enough not to intrude but able to 'catch' the keystrokes repeating...
    • CadFatherC

      Firing Button with Modifier Key

      Watching Ignoring Scheduled Pinned Locked Moved Developers' Forum
      11
      0 Votes
      11 Posts
      575 Views
      CadFatherC
      didn't notice the thread had progressed... @tig said: You could probably also write an AutoHotKeys snippet [PC only!] which would spot a click in SketchUp with a key etc, BUT it'd be mucho complicado... ahk is quite good, i can see it possible but not too good for public consumption - with compatibility etc.. @driven said: if the button you click is a tool, you can watch for modifier keys? I assume [due to lack of use case] that you want one button for 3 tools [as example]... create a simple tool with one button... on click, [activating your tool] start a timer and watch for modifier keys... if key = a activate x if key = b activate y if you run out of time if activate z is that the sort of thing your after? or have I completely misunderstood yet again... john yes, exactly that. @jim said: There's this, but Windows only and not up-to-date and needs compiled, etc. https://code.google.com/p/eventrelay/ will have a look, thanks Jim @anton_s said: There is a way, thought it will require that your extension to require AMS Library. Easy to implement. Here is a snippet: very interesting Anton, will look into it (where's a Christmas holiday when you need it?!)
    • CadFatherC

      Style validation

      Watching Ignoring Scheduled Pinned Locked Moved Developers' Forum
      8
      0 Votes
      8 Posts
      371 Views
      CadFatherC
      ok TIG, thanks for that, i shall have a go with this. i thought i wasn't too far with my first example! Thanks!
    • CadFatherC

      CadFather Icons v1.141592+

      Watching Ignoring Scheduled Pinned Locked Moved Plugins
      1
      0 Votes
      1 Posts
      229 Views
      No one has replied
    • CadFatherC

      Possible or Impossible? (or post your favourite jQuery..)

      Watching Ignoring Scheduled Pinned Locked Moved Developers' Forum
      20
      0 Votes
      20 Posts
      572 Views
      thomthomT
      best_picked - or best_face if you want to avoid getting an edge or group or whatnot. Yea, I've spent a lot of time testing things. The API docs are much better now then in 2007 when I started, but it's still lacking details.
    • CadFatherC

      [Plugin] Save as Sketchup 8 (v1.0) PC

      Watching Ignoring Scheduled Pinned Locked Moved Plugins
      9
      0 Votes
      9 Posts
      508 Views
      CadFatherC
      TIG, you are talking to the master of coding.. you just have to be patient...!
    • CadFatherC

      VfS RT

      Watching Ignoring Scheduled Pinned Locked Moved V-Ray render plugins extensions
      8
      0 Votes
      8 Posts
      394 Views
      CadFatherC
      yes, same result - i'm going to try with different subdivs cause i have a feeling it's somwething to do with the shadows. the tall cube is not touching the ground but about 2cm off the floor..
    • CadFatherC

      CadFather's Icons [v1.0]

      Watching Ignoring Scheduled Pinned Locked Moved Plugins
      8
      0 Votes
      8 Posts
      3k Views
      CadFatherC
      mainly two ways: 1 - use them instead of (replacing existing icons) 2 - use when you make a menu in a plugin. usually, but not always, a part of the script that looks like this: cmd.small_icon = 'icon_16.png' cmd.large_icon = 'icon_24.png'
    • CadFatherC

      [Plugin] Update all other scenes..

      Watching Ignoring Scheduled Pinned Locked Moved Plugins
      26
      0 Votes
      26 Posts
      1k Views
      renderizaR
      @cadfather said: Sure, and don't call it cadfather! I will do that eventually and I promise not to call it CadFather!
    • CadFatherC

      [?] Split edges cleaner

      Watching Ignoring Scheduled Pinned Locked Moved Plugins
      3
      0 Votes
      3 Posts
      136 Views
      CadFatherC
      that was fast TIG.. that maybe it, thanks Yep - that's it. i couldn't find in my list, but was there under the fredotools menu. ..fantastic! ..may Fredo be blessed! (and all of you) result: [image: IzeH_spiltzz.jpg]
    • CadFatherC

      Export images to saved file location with file name

      Watching Ignoring Scheduled Pinned Locked Moved Developers' Forum
      15
      0 Votes
      15 Posts
      465 Views
      B
      I have run into an issue when I'm working on the same image on two different computers - when exporting the Sketchup image, the Width & Height are locked (when one is edited, the other automatically matches that computer's viewport ratio). I am trying to find a way to export an image with independently filled in Width and Height resolutions. This seems to be the closest Ruby I could find to fixing my issue. Is there any way to modify this to get what I'm looking for? I export so often that I would like to create a button on a new toolbar to keep at the top of the screen, instead of entering the Ruby Console every time. Is there any way to do this?
    • 1
    • 2
    • 3
    • 4
    • 5
    • 1 / 5