Hi,
I can`t get svg.rb working.
The plugin requires REXML ruby library (what is not clearly stated), and even having that in SU7.1 produces a cryptic error:
Do you have an idea what`s the problem, and can anybody import SVG to sketchup at all?
Importing SVG
14 posts
• Page 1 of 1
Re: Importing SVG
If you read the file early on it requires a file require 'rexml/parsers/pullparser.rb' this is where it's failing Inside the Plugins folder you need a folder called rexml, inside that a folder called parsers and inside that a file called pullparser.rb - I suspect that that file will also have require/load set for other files in the folder so you need to check that too... This IS explained in the linked web-site as: You might think that the rexml is here http://www.germane-software.com/software/rexml/ [Development.zip and API_Docs.zip downloads] - and you'd will need to rename its copied folder as just rexml inside ../Plugins/ BUT it doesn't contain 'pullparser.rb' SO DON'T BOTHER !!! You actually need a full version of Ruby instead http://www.ruby-lang.org/en/ and copy the rexml folder from that !!! Aaargh! This is perhaps the least painful route http://rubyinstaller.org/downloads/ Copy this folder into ../Plugins/ and the other two .rb files here http://www.koders.com/ruby/fidFC6B854727851FAB8FC100CF0B7AB5BAE3F3F7B3.aspx?s=open3 [click Download link on left] and here http://www.koders.com/ruby/fidD93919848069320713B57FAB7E319C679FD5CA55.aspx?s=open3 [click Download link on left] - these go into ../Plugins/ It could have been made a whole lot easier ! ![]() ![]() PS: It also needs bezier.rb which you can get from here... http://sketchup.google.com/download/rubyscripts.html ![]() TIG
Re: Importing SVGThank you TIG! Life is much easier with folks like you.
![]() I`ll try to give something in my turn, too. Here is the plugin with all the needed scripts: Re: Importing SVGJust so you know, we've had this posted back in 2008 (but now removed)
viewtopic.php?f=180&t=13475 The problem is the file set.rb uses a Set class that is in conflict with SketchUp's built-in Set class, which can cause other plugins which rely on the Set class to fail (in sometimes subtle ways that are hard to debug.) It may be possible to fairly easily wrap the entire plugin in a unique namespace, but I don't think anyone has tried it. Hi
Re: Importing SVGYes, I found that.
But I think that declaring this incompatibility is much better than removing a possibility - so you don`t ban people from using a function when necessary. Re: Importing SVGDoes that mean it is very likely to risk conflicts when installing svg.rb?
I'd love to have vectors from Inkscape imported, but I don't want to mess up my plugins... ![]() Re: Importing SVGSvg.rb is ok, but it loads set.rb.
Set.rb disables smoove from sandbox tools. That`s it. So I keep both svg.rb and set.rb away from plugins folder and move them back in only when needed. Re: Importing SVGYou could try this:
'disable' set.rb by renaming it set.rb.txt edit the file ../Plugins/remxl/parsers/baseparser.rb near the start disable the require for set by prefixing the line with a #, thus #require 'set' You should still get the required 'Set' functions loaded by Sketchup for the svg tool AND sandbox... Try it this way and report back - you should then get both tools working.......... TIG
Re: Importing SVG
Before you follow the instructions: After TIG instructions: I have no knowledge of scripts, just follow the instructions. Regards to all, and I hope someone helps us. Re: Importing SVGoh, oh, I'm a bit frightened
![]() cheers Re: Importing SVGLooks like my idea isn't working as the SUp's Set has fewer methods than set.rb's Set ... F
So forget what I said earlier - you can have either svg.rb [with set.rb] working OR the Sandbox-Tools [and any other tools using 'Set' methods]... But not both. You must choose. TIG
Re: Importing SVG
Really... An English forum and you didn't even bother to use Google Translate or alike...?!? Please note that this plugin dates back to 2010... I don't think you're going to make it work with newer versions of SketchUp... Cheers
Kim Frederik
14 posts
• Page 1 of 1
|
Who is online
Users browsing this forum: Google Bot, riisgaard and 15 guests