[Plugin] Components manager plugin
-
Hello Oxer,
Version 1.12.1 should solve your issue.
Inteloide
-
Other problems
1. The Options "Auto-select instances in model" & "Auto-select instances in list" worked only the first time that I ran the plugin.
2. The Groups don't appear in the List although you have marked them in the Filters windows.
3. I don't know if this is important but when I create a "New File" with the Ruby Console opens, it appears this message:%(#FF0040)[Error: #<NoMethodError: undefined method `execute_script' for nil:NilClass>
/Users/Oxer/Library/Application Support/SketchUp 2013/SketchUp/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:132:in `maj_liste'
/Users/Oxer/Library/Application Support/SketchUp 2013/SketchUp/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:1100:in `onNewModel'
/Users/Oxer/Library/Application Support/SketchUp 2013/SketchUp/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:1073
Error: #<NoMethodError: undefined method `execute_script' for nil:NilClass>
/Users/Oxer/Library/Application Support/SketchUp 2013/SketchUp/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:132:in `maj_liste'
/Users/Oxer/Library/Application Support/SketchUp 2013/SketchUp/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:1100:in `onNewModel'
/Users/Oxer/Library/Application Support/SketchUp 2013/SketchUp/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:132
Error: #<NoMethodError: undefined method `execute_script' for nil:NilClass>
/Users/Oxer/Library/Application Support/SketchUp 2013/SketchUp/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:132:in `maj_liste'
/Users/Oxer/Library/Application Support/SketchUp 2013/SketchUp/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:1100:in `onNewModel'
/Users/Oxer/Library/Application Support/SketchUp 2013/SketchUp/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:132] -
Great work!!
All work fine now *****, nice Options window, perhaps a scrollbar, the windows size is very small on Mac and you have to resize them manually.
The translation works partially.
It works in:
- Plugins Menu
1. Titles of the windows.
1. Tooltips of the items in the List.
1. Tooltip of the toolbar icon.
1. All the strings in the Filters window.
1. String: "List update at "
1. All pop-up windows.
The rest no.
***** See the next post.
- Plugins Menu
-
Inteloide,
For me undo is working badly again, this time it says undo BGSketchup instead of undo EDIT Properties.
Besides that, if I do a push pull I can't define a distance I have to get a reference point.
I have to disable plugin and restart SU for undo or pushpull to work.
Best regards,
JQL
-
ok guys.
Last version should solve some of your issues.Oxer, for the issue of option for selecting components....very strange, everything work perfect on my PC. Is it not working with groups ? (
I didn't implemented this function for groups. I should include it).
Same remarks with Group filter. I tried successfully lot of model.
For your point 3, this error involve also JSQL issues, then this version should solved everything.
JQL please try again your undo issue, on my it works.Oxer, is this version solve the scrollbar issue in option window ?
We keep in touch.
Inteloide -
Pushpull is working nicely outside groups and components, but inside a component you still are unable to set a dimension for pushpull, or Undo. This time it doesn't even undo if you press CTRL+Z a lot.
I'm going to PM you a model for you to test.
-
I sent you a PM with my answers, but the scrollbars no appear in the Options window.
-
Hello
Just post a plugins that solve push/pull issue (and maybe some other). It was a bug not so easy to find...
Oxer, I will post you a special version that tries to add scrollbar on Safari. About translation, could you tell me exactly an example of a translation not working ? I change in version 1.12.4 the option translation text to the English to avoid wrong coding because of new option texts structure.
Version 1.12.4 :
Corrected : Issue when using push/pull tool in a component.
Optimized : Simplified attribute date change in model to open only one time for each component. -
With v1.12.4 on Mac the scrollbars continue missing and the translation works partially.
It works in:
- Plugins Menu
- Titles of the windows.
- Tooltips of the items in the List.
- Tooltip of the toolbar icon.
- All the strings in the Filters window.
- String: "List update at "
- All pop-up windows.
The rest no.
-
@oxer said:
The rest no.
Ok this means that "options" are not translated. Are all options not translated ? (remember that in current Localization.rb file I let everything in English, to try it you have to change translation).
Also, for your window size issue, I added a option to save window size, which solve temporary your size issue.
V 1.13.0 :
Added : New option to save window size
Added : Show refreshing time in the window status bar
Corrected : Remove one unused global variable -
Yes, all Options not translated. I changed the translation.
The "Save Window Size" option works fine but there is a great problem, when you call the plugin the first time all work fine, then you close the Component Manager window, the second time that you call the plugin, it appears the Component Manager window with the message: "Please refresh the list" but the buttons doesn't work, no Refresh List, no Link to file, nothing. -
Inteloide,
I tried it again today and the problems with push-pull and undo have disappeared, but now I'm seing it messing with Fredoscale and I also believe JointPushPull. I think it's because they perform changes to components and groups visually and interactively.
I think your plugin is making Fredo scale multiply a given value several times, until the mouse is clicked.
I also believe it's making JointPushPull crash.
May you have some conflicts with your observers and Fredo's?
-
@jql said:
May you have some conflicts with your observers and Fredo's?
Hello JQL,
I check a bit Fredo's plugin code, apparently nothing should make conflict...but I will ask Fredo if we can check this toegether.
Inteloide
-
But did you see what happens? Do you want me to make a video or something?
-
Hello JQL,
Yes a little video would be helpful.
Inteloide
-
Inteloide,
There you have the video. If component manager plugin is disabled FredoScale works normally.
It also works as usual on groups and sometimes on components with multiple instances.The object being stretched by FredoScale Box Stretch to Target is a component.
Thanks again for all your effort,
JQL
FredoScale_Box_Stretch_to_Target_with_Component_Manager_v1.13.0_On.swf
-
Hi there
It has been brought to my attention that this plugin can conflict with other plugins. I just got a report from a customer that experienced SketchUp crashing when using Vertex Tools. After debugging it turned out that the crashing stopped once this plugin was disabled.
I looked at the source code and I identified several problems.
The main problem is that this plugin uses observers that modifies the model in the observer events. This causes a number of issues, for instances interrupting other tools and plugins. It breaks the currently running operation if you perform model changes in observer events. It's also prone to cause crashes in SketchUp - which is happening here.
How, there is a pattern one can use to make observers safer, it's demonstrated in a code example published on GitHub: https://github.com/SketchUp/sketchup-safe-observer-events
It also defines a bunch of methods outside of any module, which in effect defines them in Kernel - which means they become available to every object that exist - big potential for clashing with other plugins.
It's recommended to contain all methods in a top level module to avoid clashing with other plugins, as well as not using global variables. I've written an article that describes this in more detail:
http://www.thomthom.net/thoughts/2012/01/golden-rules-of-sketchup-plugin-development/Also a checklist of key items to verify when publishing a plugin:
http://www.thomthom.net/thoughts/2013/02/sketchup-plugin-checklist/On a side note, not rleated to clashing, but for the sake of performance; typename is very slow. using is_a? or kind_of? is many times faster.
http://www.thomthom.net/thoughts/2011/12/never-ever-use-typename/It'd be good if you could address the issues that makes your plugin conflict with other plugins. Causing crashes is very unfortunate for the users as they may lose their work.
-
Hello Thomthom,
Thank you for your always useful remarks.
Actually I was working with JQL to solve conflict issues he had with other plugins.
The new version I just posted should solve the problem.I corrected also some coding according your advice :
I wrapped my file BGSketchup.rb in a module but I kept the global variable because it's used for other plugins (maybe I can change this later). But the global variable has a special name.
For the other variables they are replaced with module variables as per your advice.For observers, I proceed in a new way and I update entity attribute only when user is asking a specific action from the plugins (reload liste, save components, etc...) or when saving the model. Therefore it should be interferring other plugins.
(sorry, I didn't use your code....yet ;o)Once you have made some testing with your plugins and it's running ok, I will update it in the pluginstore to inform all current users.
Thanks again for your help improving this plugin.
Inteloide
-
A bug appeared in my version 1.14.3 rbz file....
Anyone who download this version must download version 1.14.4 AND remove "BGSketchup_Robot.rb" file from their plugin directory...
Sorry for this error.Inteloide
-
Hello !
What about last version of the plugins ? Does it works on your computer ?
If yes I will upload it in the pluginstore.
Thank you for your feedbacks !Inteloide
Advertisement