Preserving Colors

Is there a way to take a bunch of different colored lines, put them all on the same layer, but retain their original colors?

A line will retain its color on any layer as long as the color properties for that line are not “By layer”. If it is hard set to say green it will be green on any layer. If it is set “by layer” then it will change when moved to a different layer. You can access this through the properties pane when selecting the line or multiple lines.

Shaun is correct on his point

Be aware that a line on one layer that is displayed in Red could be displaying in red for two reasons

  1. The line has its color defined as By Layer and the color of the layer that it is on is defined as Red - so the line is Red but its color is set to ByLayer. If you move this line to another layer that has its color defined as Cyan, then on moving the line from the first to the second layer its color will become Cyan because it is using the ByLayer method
  2. The line has its color defined as Red - this overrides the color of the layer that it is on. If you move this line from one layer to another it will always be Red after the change because it’s own color is Red.

So if you select a bunch of lines and relayer them, depending on whether or not their own color is set to ByLayer or a specific color will dictate what happens to them when they move from one layer to another. If they are all self colored then they will retain their color after the move. If they are colored ByLayer then they will change color if the layers from and to have different color assignments.

If you have objects set to ByLayer, and you want to change their color to a specific color, you have to do that using normal selection methods and then change their color property.

I don’t know of a way that you can take a selection of lines on different layers that are all set to ByLayer and change their self color to that color that they are currently inheriting to lock the colors to the objects. You can select all objects on a layer and change their color to a user defined color, or you can use selection methods to select objects and change their properties.

1 Like

Thank you both for the help. My use case here is that I had a client that wanted all of the foundation lines included as 2D lines in the model. I thought it would be a lot easier to differentiate the column lines, partitions, and others from each other if I could just put it all on a 2D Foundation layer, but keep the colors different. When I standardize layers, sometimes the colors change to ByLayer, and sometimes they don’t. I was wondering if there was a way to keep them from changing. I was just trying to not have to create 15 new layers or go through and change colors on everything I wanted different.

Do the. Colors change during Standardize or is it just that the target layer. Color is different to the source layer color and the lines are set to Bylayer so they change during the process.

I would set all the objects to Bylayer and then let the layer color control the colors of the objects. You will need to have different features on different layers but that is pretty normal

You can group select many objects on multiple layers and then globally change all their properties to by later

Alan

Use the RP ‘NameByLayer’ as it has an option to apply layer colours to lines. Colours will then be retained when relayered.

2 Likes

I had forgotten about that. Usually, it is kind of annoying, but in this case exactly what I was looking for.