Component names in menu
-
Hello,
Like many of you I've created my own library of components I use the most, and keep adding into it as I go along. For this I use the 'save as' context menu when right-clicking a component, and navigate to the relevant folder on my HD.
I then give it a relevant, useful name like "WoodTable_4Chairs" for example.The problem I have is that when I next go into my own components folder in the components browser within SU, the very same recently saved component will be called something weird like 'Group33' next to the thumbnail...
When I check back into my components library folder on my drive, its still called "WoodTable_4Chairs"...So it seems some sort of meta-data is being displayed instead of the actual file name...
I can't find anywhere where to change this... Am I missing something here?Thanks for any pointers.
-
What if you still rename it in SU prior to exporting (saving as...)?
-
This component you are about to do a 'save_as' on... how have you made it ?
Have you given it a name before you get to the save_as part ?
I think you have made it a component from a Group, so it will be named something like Group#n.
Look in the Outliner and also look at it in the Component Browser's Model-tab [little-house-icon] and see what its name is - I suspect its something like Group#n.
You can rename it [and add a description] there in the top panes, then you can right-click over its icon in the pane and do the 'save_as' from there, it will then use that name as the file's default in the save-dialog that opens
Now the two should match.
To link this now external component back into the model you can then right-click and 'reload' it from the external file, now the model knows that they are linked and if you change the external component separately you can reload it into the model using this 'reload' technique... -
This is true, TIG, however when "saving a component as...", SU should respect the new name the component is saved with.
What's more interesting, if you save a component this way and import it from File y Import... it will keep the name you saved it with but not in the component browser.Also, I am really missing a link in the Component browser to the folder I set in Preferences > Files for components. It should also be there for easier access (currently this setting has almost no use at all).
-
@gaieus said:
This is true, TIG, however when "saving a component as...", SU should respect the new name the component is saved with.
What's more interesting, if you save a component this way and import it from File y Import... it will keep the name you saved it with but not in the component browser.
Also, I am really missing a link in the Component browser to the folder I set in Preferences > Files for components. It should also be there for easier access (currently this setting has almost no use at all).When you do a 'save_as' you can give the component any name you like.
It's current name within the model is the one shown in the save-dialog by default but you can change it to another name.
That way you can make modifications to a 'base' component and use eave_as [which is effectively an 'export' with a user defined name] on each version of it as a different external skp.
There are no connections between the skp file you saved externally and the model's component - this is logical, otherwise doing the multi-version save_as I outlined above would lead to ever changing links between the model's component and the most recent external skp.
If the users chooses to do a save_as on a component [either from a right-click context menu or the Component Browser] the dialog does prompt with the component's name, if the user changes this it's their choice.
If you want your model's component and the externally saved component to share a common name then DON'T change its name in the save-dialog.
Give the component the name you want it to have inside the model, then do the save_as so they'll match.
There is no reverse engineering available - when you do the save_as the name you choose does not rename the original.
Think about it, when you have a Word Document Doc1 and do a save_as on it as Doc2 you expect that the original is left unchanged and is still called Doc1 - IF you want to rename Doc1 as Doc2 that's a different process and you won't expect a save_as to do it for you.
Similarly, doing a save_as on a component in SUp won't ever affect it's original name.
I could envisage a scripted solution, where you'd have a context-menu called something like 'Export Selected Component: Renaming'... that would pop-up a similar dialog to the save_as one: you'd enter the desired name and choose the folder, before doing the save_as it would then rename the selected component's definition with that new name and finally export it using definition.save_as to the folderpath/skpname you gave...
However that isn't'save_as'
it'd be'Export Selected Component: Renaming'
-
Have a look at these screenshot, TIG:
In this one, I am saving the component "in model" into a folder I made - where you see it (in SU/Components). In the meanwhile, I give it a unique name ("Component") while saving it "as...".
As you can see in the secondary window, in this "Test" folder there is nothing yet.
But as soon as I hit the "Save" button, the new component appears - with the exact same name as it used to have (and not that I renamed it) even though in this "Test" folder, the newly saved file has the correct name. I can try to re-save as many times as I want - to no avail.
Of course, if you rename the original component prior to saving it as..., it will keep its new name so there IS a workaround however I consider this as a bug. -
I have repeated what you show and seems to me it is an attempt by SUp to actually 'reverse engineer' this save_as method and show the original name... It is a serious bug that needs fixing - I can see no use for it.
It let's you do save_as and give any name you like to the external skp, but it always displays the skp in the selection pane with its original name [which it is presumably reading from within that skp file] - right-clicking it in the pane and getting Properties shows it's folder and its real file-name ! However it always displays its original name in the pane [if you do two save_as operations then the displayed items are called Component#1 ?]
So if you have an external component made using save_as it is 'locked' to its original name - it will always display it's original name [current at the time of the save_as], even if you subsequently edit it with SUp and do a save_as of it etc - there is some flag set inside the skp that SUp is wrongly using in the browser-panes, to show its original name and the current 'real file-name' is ignored/
Renaming library components externally is therefore useless - they'll always appear in the Browser under their original name - they will insert into the model with their correct [file] name, BUT you can have lots of Component#1s displayed in a library folder, and only when you pick one does its real name appear in the top-pane etc...I wasn't aware of this bug. I urge you to report it pronto. It needs sorting.
-
@gaieus said:
Of course, if you rename the original component prior to saving it as..., it will keep its new name so there IS a workaround however I consider this as a bug.
OK so it seems I found a bug...
I'm not sure how you rename a new component if its the first time i'm saving it... TIG, you're correct in that my components are usually groups of other elements, which I first make in to components, then 'save as' components...So Gaieus how does your workaround work?
Ronan
ps. Thank you both for your help!
-
You can easily rename it in the component browser.
Another weird thing - when I dragged the "Group" component from the secondary window (that is a folder in my component folder in SU), it renamed itself to Component (which name I had given to it when saving as...)
-
To change a Component's name you can select an Instance of it and Get Entity Info [right-click, first item on context-menu to open the E'Info dialog which shows info for anything you select], and you simply change the name in the 'Definition-Name' pane - it will rename the Component with that new name - note that changing the 'Name' pane gives specific names to individual Instances of that Component and not the name of the base definition itself.
This Entity Info method is probably easiest, as you have it picked in front of you and therefore know what it should be called.You can also change the name of a Component Definition within the Model-tab of the Component-Browser as suggested below - select the component and change it's Definition-Name, you can also edit the description there too: BUT, this method is OK as long as the components are clearly identifiable - but the E'Info method above avoids any guesswork, when you have perhaps lots of doors called Group#1, Group#2 etc that might look similar in the preview icon, picking one off the model itself is less prone to error...
Advertisement