Many OS:Rendering:Color objects are being added every time the geometry tab is clicked and the model is saved again. This is causing the .osm file to become cluttered when viewed in a text editor, especially for larger models. (See diff changes below)
Ideally, the model would not add these objects each time the geometry tab is clicked and saved.
To replicate - using the attached example model -
Load in OS App and click the geometry tab
Save as a new name
Compare the two files in a text editor
A new OS:Rendering:Color object will be added each time the geometry tab is selected and the model is saved again.
Possible Solution
One possible, but maybe not ideal solution would be to remove all rendering colors before a save -
rendering_colors = model.getRenderingColorsrendering_colors.each do |color|color.removeend
Another possible solution would be to identify which constructions or surfaces are causing these colors to be generated each time and removing just those from the model before a save.
Environment
Some additional details about your environment for this issue (if relevant):
Windows 10 Enterprise 22H2
OS App 3.6.1
Context
The issue is more annoying than a real problem, but it causes a visibility issue when trying to compare meaningful changes across models.
Issue overview
Many OS:Rendering:Color objects are being added every time the geometry tab is clicked and the model is saved again. This is causing the .osm file to become cluttered when viewed in a text editor, especially for larger models. (See diff changes below)
Ideally, the model would not add these objects each time the geometry tab is clicked and saved.
To replicate - using the attached example model -
Possible Solution
One possible, but maybe not ideal solution would be to remove all rendering colors before a save -
rendering_colors = model.getRenderingColors
rendering_colors.each do |color|
color.remove
end
Another possible solution would be to identify which constructions or surfaces are causing these colors to be generated each time and removing just those from the model before a save.
Environment
Some additional details about your environment for this issue (if relevant):
Context
The issue is more annoying than a real problem, but it causes a visibility issue when trying to compare meaningful changes across models.
Example.zip