SketchUp - Referenced SU Models - TAG Folders

I guess I never noticed that TAG Folders are not imported; or rather, they are ignored when imported as an external reference model.

The TAGs themselves are, but not the container/folder.
Am I correct?
What is the intent of this behavior?
Can anyone point to documentation on this subject.

On a side note… this may explain why I can’t get an extension I’m building to work they way I want it to.

Nicholas

Yes, but if you import into a template that has the same folders the tags will fall into their proper folder.

1 Like

There is no such feature. An imported model becomes a component, with no fixed link to the original file.

You caught me.. semantics.

Were not treating this model like a fence… or some repeating component. Its a large model (like a building). Placed into another… much larger, with others. None repeat and use TAGS on their own.

What would the proper term be?

I appreciate your help.

N

I do the same. For example a building is saved out as a component and then imported into the site model. Refreshing it is manual, but I still think of it as a “reference file” even if that’s not technically what SketchUp calls them. Yes, technically it’s a component. Even if it isn’t repeated, it allows you to right click and “Reload” the component. I don’t import an entire file, by the way, I import a component that is right clicked and saved out.

There is also an extension that lets you save and load tag sets:Tag and Folder Profiles by @3DxJFD

2 Likes

Dunno. But it seems to be that a tag is ‘part’ of a component/model (whether in the model space, or as a component in its own model), whereas Tag Folders are arrangements of Tags per ‘model/file’. That’s why templates work (Tag Folders are saved to them).

The extension mentioned tries to solve the problem at the extension / in model level vs the custom template level. Save a Tag Folder structure as a Profile in the ‘from’ model, and then load the Profile in the ‘to’ model: Tag and Folder Profiles | SketchUp Extension Warehouse

2 Likes

Thats an interesting extension. I noticed that on the warehouse page you have it listed to work on Windows but not Mac. But after downloading and installing it, seems to work on my Mac. But, the color and line styles are not saved. Is that just a MacOS issue or is that as intended?

I’ve been working on something similar… I can export a CSV with all data information. And can import line style and its changes. But I can’t import colors/ opacity and folders. I like your approach… but I haven’t looked at what you’re doing.

Yes, I just listed as compatible with Windows because I don’t have a Mac to test on. But @RTCool has been using it and a couple other extensions and they seem to be working fine. I’ve seen a DS_Store.? file used in Mac extensions. I believe they may store some settings. But not sure and can’t test.

It doesn’t save colors and line styles. That might be something to try to add. I was also thinking a ‘preview’ or display of Profiles might be a nice addition. I do have a version that can create tags and folders and displays the folder trees for quickly adding tags and building folder structures.

But you’re saying you can get the colors exported in csv but then you aren’t getting them to display correctly with the tags? I will say that I’m using a json file.

…looks like you’re typing.

Yeah, a few years back I started splitting the model up when I was doing residential remodels. It made it easier to reference in LayOut. One for as-builts. One for design development and so on.

Now that I’m doing outdoor challenge courses, different models can be a mile away from each other, And that by its very nature can be a hot mess to work with.
Also the axis can be a very long way away.
Add that the topo/nodes from LIDAR can be very heavy on the GPU… I kinda have to split it up.

That extension looks promising for a solution.
Thanks!

Nicholas

Here’s what I’m working on…

Feel free to do what ever you want with it.
My intent with most things I build is to share them freely.

TagCSVTool_v1.0.5.rbz (5.3 KB)

1 Like

I just did a test and I think I have tag colors saving to profiles. I’m going to look at your code and then I’ll check back in.

Dude, I like the focus of your extensions!
Especially that Tag Outliner. I need to check it out…

Solving issues that have frustrated me for years

Check out this extension I made. I need to make a few tweaks, but its does what I need.

Nicholas

1 Like

Thanks! I appreciate you saying so. I think Tag Outliner is pretty handy and ‘just works’.

I saw your post. I like the idea of it. And your concise legalese. But I didn’t try it. I’m making mods to display Profiles with tag colors and then I’m going to see what you are doing and if colors can be made to play nice in your extension. I think so!

1 Like

Okay, the colors already play nice.

You’re getting tag folders but only if they have tag in them. Then even if they do, the folders aren’t being imported. Or something like that plus other bad stuff. I’ve seen that before.

I fought a battle of wills with your code and the code won. The idea as to try to get paths in the Folder column rows. Since I couldn’t get that to work, I went back to my extension and tried using the json that handles the Tag Folder structures better and ‘converting’ that to cvs. The resultant cvs is less readable than your format. So, there are Folder and Tag rows but this way I could get the Folder Paths. And it works.

It operates like this:

Then the csv looks like this:

Anyway, I guess I’m using the json as an intermediate step because I couldn’t get the cvs from your code to work. Now that I have something workable, I’m going to look at your code again to see if friendly relations can be established between the code. Maybe just gut your code and have it create the json-to-cvs? If that’s doable then you get a little extra something in your extension folder and a little less readable CVS but something that works. I’ll check back if I can get that going.

1 Like

Tag Folders in ND Tag CVS Tool extension. Compatible with the Tag and Folder Profiles.

Need to test and monkey around to make sure this is working. Basically, we needed to get the full folder tree to be able to rebuild it. I’ll check back in.

1 Like

A few comments, I’m not being critical or whatever, just sharing my experience. :innocent:

There are a few properties of Tags/folders that make importing/exporting a bit difficult:

'1) Unlike Tags, Tagfolders do not need to have a unique name. However, these folders are different objects with the same name. So if you only look at the name, it may not be what you or others think will be exported/imported.

The example below is extreme - the names like these make no sense, but they are possible, so we need to take them into account.(?)
For example, if the target model contains a structure like this:

Folder/Folder/Tag1
Folder/Folder/Tag2

The source model contains a structure like this:
Folder/Folder/Tag3

How do you make a new structure? Like this?

Folder/Folder/Tag1
Folder/Folder/Tag2
Folder/Folder/Tag3

or ?

Folder/Folder/Tag1
             /Tag3
Folder/Folder/Tag2

or ??


'2) The visibility of Tags/folders can depends on the scene.


'3) Only the R,G,B part of the Tag color is passed through. Transparency data cannot be read or written with the Ruby API. (Well, I have a half-finished plugin somewhere, how can I do it anyway…)

If you have manually assigned a material to Tag (not just a color), only the average colors can be read and written. This is an old missing features (bug) in the API.

1 Like

Agreed, but Curic LA and 5D+ Auto Tag (my extension) can export/import tags with transparency and textures (materials).

For part 1, do you mean the individual top-level folders and their children are correct but not the structure (order) of the parent folders? That is an issue. Or something else?

Can we rely on hope and presume people using folders for organization will take the time to name their folders? :slight_smile:

The folder is not clearly defined by its name. Taking a folder path can help a little, but you don’t know whether you are putting the tag named Tag3 in a path with the same structure as the target, or whether you are creating a similar path that already exists and putting Tag3 there.

In the model - although it doesn’t make much sense - there can be all 100 (or whatever) folders named as “Folder” in any tree-structure, but if you were to transfer these to another similar model it would be quite difficult to decide which one corresponds to which. In some cases may not matter, in other ceses it does, eg. you may also need to check whic folder visible on what scenes…etc.

Of course, it is be good to be able to create something like Floor0/Doors; Floor1/Doors; but this has not been really worked out. That is probably why the folder structure is not copied/merged - like the tags- when you transfer components from one model to another. It is hard to write such an algorithm. (I think).
Therefore, yes, you can assume - or tell the user - to use unique names for Folders… if they want to use your extension.

But in my opinion, the same name should not be allowed in the first place.

Hmm, haven’t fixed that for all possibilities. But can change order of loading:

I suppose someone could strategically save Profiles to build ‘out of order’ Tag Folder structures.

I wonder if this sort of ‘weird and wild’ possibility should be accounted for? I mean it accommodates ‘bad practice’ - not that someone might come up with a good reason.

But I did go in and fix the 123, ABC ascending sort so Preview matches loaded state. That was needed.

1 Like