Workflow speed for object selection

Hi there :slight_smile:

I want to relay something that happens so many times as part of my workflow, and where I feel that a lot of time could be saved (jump to end for request).

When working on large files with heaps of geometry, layer management is critical.
When files start to look like this;

and wireframe is the only possible display, I am constantly ‘isolating’ and ‘unisolating’ to be able to work only on the desired geometry.

The typical workflow is
select objects whose layers need to be isolated>go to layers tab>select tools>'select object layer>with all layers of selected objects highlighted>right click, select objects or sublayer objects>isolate.

Can you recommend any better way?

I believe that something from Illustrator could save lots of time to this workflow.

In this image, I have selected some objects, and on the right, you can see the exact layers that these objects are on because Illustrator jumps to those layers and highlights them in view. From here, I can easily select all of the contents in those layers by CTRL or Shift + clicking the small circles to the left of the coloured squares (image below).

If this was only for one layer in illustrator, it is literally 2 clicks to select all contents in that layer; Select object, (illustrator jumps to that layer in the layers panel and highlights it) select circle of layer. Then I can change whatever such as lineweight etc.

If this ease of object selection was in Rhino, it would be a dream for me… Something like

Select some objects of the layers whose objects I want to isolate> rhino jumps to those layers and highlights them> click some sort of button>all objects on those layers are selected. Then I can alias my isolate command easily and quickly.

Fanboy architecture student

Hi @jdelavaulx
Highlighting layers has been discussed before (many times) and I think the main reason for not doing it, is speed (as it takes time to update the layers list, especially if there’s a lot of layers). For your workflow, I’d either make aliases or keyboard shortcuts to speed things up. If you select an object(s) on the layers you need to isolate, you can use SelectLayer to bring up a dialog box with the appropriate layers already selected, press enter and then run Isolate. If you have both commands as an alias, it takes less than 2 seconds.
HTH, Jakob

create a new button, copy and paste below into the command field.

! _-RunPythonScript (
import rhinoscriptsyntax as rs
import scriptcontext as sc

    obj = rs.SelectedObjects()
    name = rs.ObjectLayer(obj[0])
    rhobjs = sc.doc.Objects.FindByLayer(name)
    for rhobj in rhobjs: rhobj.Select(True)

Ah thanks Normand… will definitely look at this!

Hi Rgr
Thanks so much, will look into this tomorrow.

Thank you so much Jakob! This works an absolute treat… gonna save so many clicks with aliases.

Do you know if there’s anyway in the alias macro to automate the ‘OK’ command once the SelLayer dialogue box comes up? Because most of the time, it would be used as part of the macro


Hi rgr,
I tried this, but the behaviour is quite unpredictable. In the image below, I selected one of each of the curve triplets on their different layers, then pressed the newly created button.

Once the button has been pressed, only one of the layers objects have been added (in this case, the purple layered objects; but in other cases, it’s unpredictable which will be added).

it does work as intended, just not as you intended it :smiley:
this does.

import rhinoscriptsyntax as rs
import scriptcontext as sc
from sets import Set

    selectedobjs = rs.SelectedObjects()    
    names = []
    for obj in selectedobjs:
    names = Set(names)
    rhObjs = []
    for name in names:
    for rhobj in rhObjs: rhobj.Select(True)
1 Like

Thanks so much rgr,
This is the first time I’ve looked into python and rhino scripts… finally got it to work!