ℹ️ Licensed Extensions | FredoBatch, ElevationProfile, FredoSketch, LayOps, MatSim and Pic2Shape will require license from Sept 1st More Info
  • Cross domain testing with ajax and JSONP

    7
    0 Votes
    7 Posts
    775 Views
    G
    I was hoping to do a POST because I will be updating a database with my real JSONP call. Unfortunately when I do a check on the php side I see that the call is turned into a GET. I agree that a timeout and an on error function is a good idea. My main question is will this work with OSX Lion. I was hoping that someone could try it out and tell me.
  • Move instances softly, using the mouse

    4
    0 Votes
    4 Posts
    265 Views
    D
    @dacastror said: ... I wanted to look at your plugins and I did not find them, look in the pluginstore and select search by author... you won't find them, there's a couple on limited beta release and a few of mac only dev tools that almost no-one else has even seen... I keep adding to them on the day I decide to release, then I want to test again, ect... etc... I PM the closest to release one if you want to comment on it... john
  • How to fetch all material in SKP via Ruby?

    2
    0 Votes
    2 Posts
    224 Views
    TIGT
    You can only access the Materials that are loaded into the Model. You can iterate the list and get various aspects of the material. Sketchup.active_model.materials.each{|material| puts material.name puts material.display_name puts material.color puts material.alpha puts material.texture ### and so on... puts } I have included the puts so the info is shown in the Ruby Console but of course you can do other things with that... A Material's '.display_name' is not always the same as the '.name' [depends on its creation/source] A Texture can also be further probed to get info like its image, size and so on... Read the API http://www.sketchup.com/intl/en/developer/docs/classes.php If you must get details of SKM files not yet loaded [and not loadable using native API methods] then you could look at my SKMtools which offer many additional tools to import/export/interrogate SKM files etc... But please learn to walk before you run
  • How to check if two ComponentInstances are in contact?

    3
    0 Votes
    3 Posts
    254 Views
    R
    Thank you sir.
  • ViewObserver doesn't fire messages on Zoom tool

    5
    0 Votes
    5 Posts
    262 Views
    Chris FullmerC
    Yeah, I can see this too. Thanks for reporting it. We've got it logged in our bug database now Chris
  • Negative uniform scale

    10
    0 Votes
    10 Posts
    390 Views
    R
    @tt_su said: That disappearing group (visually) sure looks like a bug. I'll file a bug internally (SU-29499). Meanwhile, the workaround is to specify scaling in X Y and Z explicitly. Ok, Thom. It is a small bug but it took me a long time to be assured it was not my code fault and try another way to do it.
  • Problem about ruby searching path in sketchup

    9
    0 Votes
    9 Posts
    907 Views
    W
    @dan rathbun said: I've already written a patch, and TIG has updated it twice. See: Re: Sketucation plugin load error Thank you! I use the patch,but there is still different. when sketchup install in drive c,and start with shortcut in desktop Encoding.find("locale") #<Encoding;GBK> when sketchup install in drive c,puts the patch file in tools folder,then start sketchup with shortcut in desktop Encoding.find("locale") #<Encoding;ASCII-8BIT> This different will lead some error if filename uesed some Chinese character. The patch file is still missing something?
  • Gluing Text label (in creation / modification)

    2
    0 Votes
    2 Posts
    195 Views
    TIGT
    I think the new Dim methods do allow you to get the 'entity tree' for a Dim's two start/end. You can also specify them when adding a new Dim - start=/end=... Unfortunately Text does not have the equivalent linking possibilities for its arrowhead. There are many Text methods missing - these were discussed at length at last year's BaseCamp - as were Dims, but only a few got through...
  • Can a Ruby tool return a value to a 'calling' program?

    5
    0 Votes
    5 Posts
    294 Views
    Dan RathbunD
    @johnwmcc said: Is it possible or allowable to have module-wide variables that aren't global? YES. ALL of your plugins should be within a company or author namespace module. Each of your separate plugins would be within a sub-module of that toplevel module. Let us say for example your toplevel module is named McC and within that you define a @@last_point variable. You can also define getter and setter methods to set and access that variable within the toplevel module: module McC def McC;;last_point @@last_point end def McC;;;astPoint=(pt) @@last_point = pt.is_a?(Geom;;Point3d) ? pt ; Geom;;Point3d.new(0,0,0) end end # module McC OR you could define your shared functionality within a mixin module, and then include it within any of your sub-modules or classes, with which you want to share it with. See the the "Pick-Axe" book on Programming Ruby. It's in the Ruby Resources thread. AND also online in HTML format.
  • WebDialog encoding bug found!

    44
    0 Votes
    44 Posts
    2k Views
    G
    Sketchup 2014 Mac 10.9.2 testing text in Simplified Chinese [image: 023i_encoding_issue_14.0.4899.png]
  • Context menu in Materials Window (Inspector)?

    2
    0 Votes
    2 Posts
    249 Views
    tt_suT
    Afraid not. But I think it sounds like a useful thing. I'd recommend you file a feature request. (Please include use case - it helps so much more than just the technical request.)
  • Why does this code break?

    9
    0 Votes
    9 Posts
    482 Views
    J
    The advantage of code tags is they can easily be copied and pasted in a code editor, or one of the SketchUp console dialogs. I have my editor and SketchUp set up[1] where I can run the pasted code in SketchUp with the push of a key. So testing posted code is fast and easy - copy, paste, run. That's why it's important to post "run-able" code - leaving variables and constants undefined makes it harder to help. [1] https://github.com/noelwarr/su-tunnel
  • Location API

    7
    0 Votes
    7 Posts
    605 Views
    F
    @juantxo said: It's a pro feature. Just click mountains icon. Thanks! Unfortunately this didn't give me the level of detail I'm after (can't zoom in far enough).
  • Some menus don't open during a custom tool operation

    11
    0 Votes
    11 Posts
    327 Views
    tt_suT
    Yes, view.invalidate will tell SketchUp to redraw. It doesn't redraw immediately, but let SketchUp manage update rate. Not sure how this is related to dialogs, focus and ALT key though...
  • Face to cam script for PDF3D

    4
    0 Votes
    4 Posts
    862 Views
    juan974J
    finally the problem was tan(alpha)=tan(alpha+180°) here the result...
  • How to open attributes ?

    2
    0 Votes
    2 Posts
    195 Views
    Dan RathbunD
    Entity#get_attribute() Entity#set_attribute() The dictionary name is "dynamic_attributes"
  • Why is a box deleted / Why is a box not a manifold?

    7
    0 Votes
    7 Posts
    651 Views
    tt_suT
    There is no need to explode - just don't create two groups. Change this: bbx1 = Sketchup.active_model.entities.add_group g1 = bbx1.entities.add_group face1 = g1.entities.add_face boxpts face1.reverse! face1.pushpull(bbxmax.z-bbxmin.z ) to bbx1 = Sketchup.active_model.entities.add_group face1 = bbx1.entities.add_face boxpts face1.reverse! face1.pushpull(bbxmax.z-bbxmin.z ) If you read your code carefully you will see that you call add_group twice, once in the root entities element and once in the first group you created.
  • Support for Gems with Native Extensions?

    3
    0 Votes
    3 Posts
    234 Views
    S
    On Mac OS X, even with XCode and command line developer tools installed, the SU installation of Ruby is not set up to enable compiling and installation of most C-library Gems. For example, one Gem I attempted assumed that there was an executable Ruby interpreter in the SU Ruby Framework where the Gem library lives (there is not - only the dynamic library loaded by SU). Fixing this requires loading a 32-bit Ruby compatible with SU, since the native installation is 64-bit. But even then the generated Makefile and other scripts fail due to problems with configuration. For example, Ruby was launched with an illegal command line option to one of the install scripts. In the end I hand-edited things and got the Gem to compile and install, only to discover as TT points out that SU's Ruby intentionally omits certain standard library components that were found to crash SU. Bottom line: with enough determination you can build a compiled-C Gem, but don't be surprised if libraries it wants are missing or if it BugSplats SU! Steve
  • Incompatible character encodings loading .so files

    9
    0 Votes
    9 Posts
    692 Views
    Dan RathbunD
    @al hart said: Is GetShortPathName in ruby or in Win32API.so? Neither. It is in "Kernel32.dll", and you use either Win32API or DL class objects to wrap calls into that native library. See: [MSDN : GetShortPathName()](http://msdn.microsoft.com/en-us/library/windows/desktop/aa364989(v) Ruby : DL library .. and since DL ( really is deprecated, and now a wrapper into Fiddle calls,): Ruby : Fiddle library
  • How to transform InputPoint to local coordinate system?

    19
    0 Votes
    19 Posts
    1k Views
    R
    @unknownuser said: Postby tt_su » Tue Mar 18, 2014 8:08 am When you get identity transformation, did you check the depth? Maybe the position of IP is coming from an inferred point and therefore isn't coming from inside the group/component you click on? The bug reported by Freddo a few messages above seems to be related to inference points indeed. I always get the identity from ip.transformation when the position of the cursor is along an inference line. Besides that, along inference lines, the ip.depth equals 0 and the ip.degree_of_freedom equals 1 independent whether a face was picked by the InputPoint or not. Even along inference lines, the InputPoint position seems to be correct. Update: Along inference lines, the InputPoint position seems to be the position of the point on the inference line and not of the cursor position. Ronaldo

Advertisement