[Plugin] Components manager plugin
-
This is a plugin to manage components in your model
This plugin could be useful for mechanical system designers and others, who use of a lot of components, and modify components separately from the complete model.
Main functions :
- Tells you if your model components are up to date (compared with saved files).
- Allow you to update (upload/save) all components in your model at same time
- Add relative link (path) to your components (ex : â..\test.skpâ instead of âc:\a\b\c\test.skpâ) : This allows you to change model location without need to update all link when you want to upload a component.
- Add possibility to manage revsion level of a component (files like "c:\toto rev 3.skp"). If a higher level is found, it compares/uploads it !
Install :
Just add it as an extension or unzip files in Plugins directoryTool access :
- It adds a menu : Plugins/BGSketchup/Component manager
- It detects also OS language and translates to yours (only English and French support by now, you can freely add a new language by adding it in loclization.rb file. In this case, please send the file ;o) )
Interface explainations:
On top : the list of components in your model.- Click on one element to see some information on it, at bottom of window.
- Icons reflect component status :
-> Blue : not linked to a file
-> Green : up to date (file = component in model)
-> Orange : broken link between file and model
-> Red : not up to date (file <> component in model)
-> Mauve : Group (added only if there is component inside)
-> Red triangle in right bottom corner : sub-component(s) present
Model modification implications :
- It adds attribute to component with a relative link and modification date of the component
- It adds observers to model entities to check if something changed.
Known limitations :
- It was tried on windows 7 with sketchup 8 Pro and 2013 with internet explorer 11.
- For Mac users, it should work...or pending, pending full tests.
- The list is not updating âin real timeâ. I guess it could slow down the system. Maybe adding an option could be relevant.
Version history :
1.14.8 :
Optimized : Move JQuery folder in root BGSketchup folder, in order to reduce plugin size
Optimized : Language names now appear fully in Options
Optimized : Change javascript error message in more accurate details
Optimized : Some coding correction, thanks to Aerilius1.14.7:
Corrected : Wrap localization in module to avoid interferences
Corrected : When clicking on a raw object in model, the auto-selection in the list didn't worked anymore (Thanks Ole to saw this bug)
Corrected : Change one French translation
Corrected : When openning a new model, the list was not refreshing. Now it will, only if window is shown.
Optimized : Add Html function to catch errors in javascript (mainly for SU 2014, but also for Safari)Thank you for any feedback
-
@inteloide said:
Hello,
I would like to propose you a free plugin which allows you to manage component. This plugin is for sure not 100% complete but do the job required. I would like you to test it and give me your feedback for improvements.
Main functions :
- Tells you if your model components are up to date against saved files.
- Allow you to update (upload/save) all components in your model at same time
- Add relative link (path) to your components (ex : â..\test.skpâ instead of âc:\a\b\c\test.skpâ) : This allows you to change model location without need to update all link
Before trying it, i'd like to understand better
It seems complicated to me
Could you explain what a relative link is?
As i understand the way components work in sketchup, if a sketchup model includes components, they are saved with the model file , so when you move it, you don't have to bother about relative links..
so why would you have to update links?
-
Hello,
First, I just update the plugin with some bug corrections.
Secondly, to answer your question :
The main idea is to be able to update a model if component of the model changed, even if the model directory changed also.
Take one example :
I have one drawing saved in "c:\toto\final\test.skp"
This drawing use one component I saved in "c:\toto\component.skp"
For some reason I modifed the component, it's easy to update it in SU (just you don't know in SU if component changed or not)
But if changed also the folder with model and component from "c:\toto" to "d:\tata" (for example I saved it on USB key or on network) ?With relative link, it doesn't matter : component is saved in "..\component.skp", so nothing to do with "c:\toto" or "d:\tata".
The attempt of this plugins is to have a "Layout references manager" like, but also in relative link.
I hope this is more clear for you, if not, please do not hesitate to reply
-
Just updated with followon corrections :
Add automatic link between version in "about" prompt and the extension version
Add french translation in extension description
Improve component loading, in sub-routing in order to reduce file size
Make messages with "'" characters, in HTML, works.
Reduce icons size to 23*23 to fit in same window width, due to "options" added button
Added options prompt, removed the option menu
Correct relatif link function error in BGSketchup.rb
Correct error while saving all definitions
-
1.2 full version history :
Version history :
1.2: Added : New option to show or not groups without sub-components
Added : Update progress shown in status bar
Added : Options are saved in model
Optimized : Delete the global variable for reverse list of definition (not used anymore)
Optimized : Update automatically the list when changing options
Corrected : Add EN translation for "Group without name" in liste
Corrected : When component include groups that mustn't be shown, icons showed a sub-directory
Corrected : Replace openpanel by savepanel when asking for saving path
Thank you for your feedbacks.
-
@inteloide said:
Hello,
I hope this is more clear for you, if not, please do not hesitate to reply
i downloaded the plugin, but i don't understand how to use it
I have a model made of components, but the components manager window is empty, i don't understand how to use the icons below
could you describe step by step how to use the plugin, with a simple, from the blank sketchup window?
-
ok, I will try to make a little video (but not today).
Normally, when you open a model, the widow shoud not be empty. If it's the case, an error has occured. May I ask to run the ruby consol, open a model and send me the consol error (if there is...)
Also, I insist, for sure on Mac it should not work, as I don't know how Mac filesystem works. If required, I could spend more time on this, if a Mac user help to verify it works.For the icons below, from right to left (you can have help with keeping mouse on icon):
-Update the list (you may try this if your Windows is empty)
-Select in Sketchup the component selected in the list
-Change component path to the file
-Save selected component
-Upload selected component from file
-Save all components
-Upload all components from files
-Options
-About -
@inteloide said:
ok, I will try to make a little video (but not today).
Normally, when you open a model, the widow shoud not be empty. If it's the case, an error has occured. May I ask to run the ruby consol, open a model and send me the consol error (if there is...)
i get this error message in the console ruby
Error: #<NameError: uninitialized constant BGSketchup_Composants::Initialise_les_observers>
C:/Archivos de programa/Google/Google SketchUp 8/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:482:in `onOpenModel'
C:/Archivos de programa/Google/Google SketchUp 8/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:482with another model:
Error: #<NameError: uninitialized constant BGSketchup_Composants::Initialise_les_observers>
C:/Archivos de programa/Google/Google SketchUp 8/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:482:in `onOpenModel'
C:/Archivos de programa/Google/Google SketchUp 8/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:474 -
Hello Glro,
I just put another version with the bug corrected.
Actually, I have shortcut on my computer to skp file, I don't use File/Open from sketchup, and, of course..., ther was a bug Inside the procedure when openning.
Please try and tells me if it's ok now. -
@inteloide said:
ok, I will try to make a little video (but not today).
Normally, when you open a model, the widow shoud not be empty.
...
For the icons below, from right to left (you can have help with keeping mouse on icon):
-Update the list (you may try this if your Windows is empty)i downloaded v 1.3
i don't have error message when loading a model , but the window is still empty
if i clic on the further left button (update the list), i get this error message in the console ruby
Error: #<NoMethodError: undefined method
entities' for #<Sketchup::ComponentInstance:0xde80050>> C:/Archivos de programa/Google/Google SketchUp 8/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:63:in
liste_composants'
C:/Archivos de programa/Google/Google SketchUp 8/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:44:inmaj_liste' C:/Archivos de programa/Google/Google SketchUp 8/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:43:in
each'
C:/Archivos de programa/Google/Google SketchUp 8/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:43:inmaj_liste' C:/Archivos de programa/Google/Google SketchUp 8/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:24:in
demarrer'
C:/Archivos de programa/Google/Google SketchUp 8/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:63:in `call'
C:/Archivos de programa/Google/Google SketchUp 8/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:63 -
Hello Glro,
It looks like you ran the plugin in SU 2013, in which I didn't try.
But I tried it and correct the error you had. Please download new version 1.3.1, which now works on SU 2013.
Thank for keeping me in touch. -
@inteloide said:
Hello Glro,
It looks like you ran the plugin in SU 2013, in which I didn't try.
But I tried it and correct the error you had. Please download new version 1.3.1, which now works on SU 2013.
Thank for keeping me in touch.I use SU 8
With the new version of your plugin, i get a list clicking on the further left button of your popup window
But when i clic ont he next button to the right, the elected components don't match with the name in the window
Tne component name selected should be KLC4, but it selects KEMB
The same with KLC1: selects KEMBwhich happens to be in first position in your window...
I tried the other buttons, but since i don't understand what thaey stand for, i cannot say much
the 3rd from the right gives this error message:
Error: #<NoMethodError: undefined method
entities' for #<Sketchup::ComponentInstance:0xc9888f0>> C:/Archivos de programa/Google/Google SketchUp 8/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:332:in
upload'
C:/Archivos de programa/Google/Google SketchUp 8/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:317:inrecharger_definitions' C:/Archivos de programa/Google/Google SketchUp 8/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:316:in
each'
C:/Archivos de programa/Google/Google SketchUp 8/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:316:inrecharger_definitions' C:/Archivos de programa/Google/Google SketchUp 8/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:28:in
demarrer'
C:/Archivos de programa/Google/Google SketchUp 8/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:332:in `call'
C:/Archivos de programa/Google/Google SketchUp 8/Plugins/BGSketchup/Composants/Rb/Composants_Main.rb:332 -
Hi Inteloide,
Wow this looks promising. It reminds me of TIG's Xref tool. I won't be able to try it for a couple days but for a person who uses "offsite" components because I tend to edit them separately, this is like the Xref tool on steroids. Thank you! EB. -
@elibjr said:
Hi Inteloide,
Wow this looks promising. It reminds me of TIG's Xref tool. I won't be able to try it for a couple days but for a person who uses "offsite" components because I tend to edit them separately, this is like the Xref tool on steroids. Thank you! EB.Thank you for these encouragements ! I hope it will works 100% soon.
Glro : I corrected bugs thank to your PM. Now it works ok on version 1.3.2.
ACTUALLY, EVERYBODY WHO DOWNLOADED V1.3.1 SHOULD DOWNLOAD V1.3.2, because bug was consequent : the selected element doesn't match the real element in some cases.Glro, thank to your sample, I think that the best would be also to have the possibility to collapse all instances in the same list element to reduce the number of lines in the list.
Maybe something like :
(4) KPI3
(6) KPI4
...
instead of ahving 4 times KPI3 and 6 times KPI4.=> I try to add this function at same time than help file.
-
@inteloide said:
Glro : I corrected bugs thank to your PM. Now it works ok on version 1.3.2.
.. I think that the best would be also to have the possibility to collapse all instances in the same list element to reduce the number of lines in the list.
Maybe something like :
(4) KPI3
(6) KPI4
...
instead of ahving 4 times KPI3 and 6 times KPI4.=> I try to add this function at same time than help file.
v1.3.2 works on my computer; the selected component matches the one selected in the window
i tried the buttons, with a model made of components
the 4th one from the left launches a popup window proposing to register the component again
if i do so, its name turns to green in the window
but i don't understand how useful it can be
if i close this model and begin a new one from scratch, the component definitions remain in the window... i have to close it and open it again to refresh
if i drag components into the sketchup window, their name in the component manager window are written in orange, no link is made...
i don't understand; maybe the help document you prepare will be useful
-
Inteloide,
I've been wanting something like this forever. Even if I don't deal with mechanic enginnering the amount of components and xrefs I use is very hard to manage with native SU tools.
I'll give it a spin immediately and tell you about it's usage and any bugs I find out.
Thanks and best regards,
EDIT: I noticed only 5 downloads this is not consistent with the usefulness of your plugin. Did you try publishing it in Sketchucation Plugin Store. There is a form for that and that can get you a whole lot more downloads...
JQL
-
Thank you JQL, that make me "boost".
Two things :
- I wanted to post officially the plugin when working 100% ok. Glro already help me on that even if I desesperate to explain how useful the plugin could be.
-I cannot find where to post a plugin, I looked in the pluginstore but couldn't find easily... I'll ask SketchUcation team how to proceed.
After some feedback and maybe 2-3 improvment I have in my mind and I will officially post it. Hope this will be done for end of week.
In few seconds, I post the new version 1.4.0 with interesting updates :
Added : Options are now saved in My Documents folder instead of Inside Model
Added : Option to select automatically the instances in the model (yes by default)
Added : Number of instances of components beside component definition name, ex : toto (*3), means 3 instances in the branch of the list
Added : Plugin version in title for more traceability
Added : Update list when openning an existing file or creating a new file
Removed : Progress in Sketchup state bar (I will try in implement again later)
Removed : Old code for sub-menu options
Corrected : Error in observers for new model and open model
Corrected : Components in root of the model were duplicated in the list : not anymore
- I wanted to post officially the plugin when working 100% ok. Glro already help me on that even if I desesperate to explain how useful the plugin could be.
-
I'll add you to the Plugin Author group tomorrow and get this listed in the PluginStore
Thanks for sharing your plugin here
-
ok thanks !
Just post version 1.4.1, as Win32API.so file is required, for option saving.
It didn't saw it as it was included on my computer with other plugin I have... -
@inteloide said:
ok thanks !
Just post version 1.4.1, as Win32API.so file is required, for option saving.
It didn't saw it as it was included on my computer with other plugin I have...version 1.4.1 lists components as you wrote
here is a screen shot of my screen
All components came previously from my components folder
for the components written in green, I modified the definition path using the 3rd button from the left; that is why they are written in green
I didn't do it for the components written in orange
For this particular component written in orange, i tried to reload the existing definition, and failed...
Why is it necessary to create manually a new definition, anyway, since the address of the component is known (shown at the bottom of the window)?
Why is it that the plugin does not go directly to the adress of the component and check if it is up to date?
Maybe i don't understand well the definition of "definition"...
Advertisement