Force Select in Rhino 5?

The problem I’m trying to solve: working with a document with many layers, I commonly want to select an object that’s on a locked layer, or is locked via the ‘Lock’ command. Is there a way to ‘force select’ objects that are currently ‘un-selectable’ ?

My current solution is to unlock all layers, select the object, determine its layer in the properties panel, then re-lock all the layers that were previously locked, except the layer containing my desired object. Anyone know a better way?

Thanks,
Steven

Hi Steven - for locked objects (not layers) you can use UnlockSelected to get at specific objects. For layers, I think, off hand, that it would require a script to do what you want.

@StevenV_Gizmo - I think the attached Python does what you need, but only outside of a running command, it will not help once a command has started and is looking for objects.

Use RunPythonScript and point that at the py file. or use

! _-RunPythonScript "Full path to py file inside double quotes"

The latter can be put on a button or alias.
SelectFromLocked.py (2.4 KB)

This thing might be slow in heavy files, I have not tried…

-Pascal

Maybe just be able to see Properties of any object, locked or not. I would love to see Locked just an attribute to protect the object, or the entire layer, not a barrier to keep you from seeing it’s properties.

Hi Abraham - trouble is, one of the key advantages of locking, that is, not entering into the selection candidates, would be lost.

-Pascal

What I’m proposing is not the ability to actually select it in the sense that it becomes editable, but “just” to expose the Properties only. Then at minimum you could quickly find the right layer to unlock, or maybe even toggle a “locked-unlocked” attribute in the Properties window.

I’m probably guilty of working too fast sometimes and not doing all the layer housekeeping I should, so sometimes I leave things on the wrong layer without noticing. Then when I want to edit it I need to start unlocking layers until I can find the right one or unlock all and manually re-lock the layers I want, or reset a layer state if I saved one.

Hi Abraham - and how would you access the properties if you could not select the object? If you lock objects, it’s because you don’t want to be able to select them, correct? Say you click where there is a curve and a bunch of locked objects - under your scenario, you’d get the pop up menu asking what you wanted to select, which completely defeats one of the key uses of locking. Or say you window around your curve - a bunch of other objects will appear to be selected, but some are locked- how do you tell what you can do next?

-Pascal

How about an icon on the Select toolbar, or maybe somewhere else that would start a command to “Expose Properties”. Then you could choose which objects you want to see properties for irrespective of if they are locked or unlocked. Hit enter to exit. So locked objects would stay properly locked and not be constantly popping up menus.

@abrahamwechter

how about macro command to unlock all layers?
Then cntrl z to go back to previous state?
@pascal is this below script correct to unlock all?

Yes setting up button to Unlock All Layers and then Restore Previous Layer State would probably work just fine. And probably much simpler to implement than exposing properties regardless of locked/unlocked. Still would prefer to just be able to see the properties of any object without necessarily making it editable but maybe it’s not worth the trouble.

Thanks for the advice guys. Here’s where I stand:

@pascal - your [SelectFromLocked.py] script worked perfectly as long as the parent layer(s) were unlocked. Is there a way to make it work for child layers whose parent layers are locked? I’m learning python right now, so hopefully I should be able to make this happen myself in the near future.

@Toshiaki_Takano - That macro is definitely useful, though if I can get pascal’s script to work, it will be a little quicker.

Thanks again!

Hi Steven - I see… you mean you want it to work properly? I’ll take a look…

@StevenV_Gizmo - see how that works now - I’ve updated the script in my post above.

-Pascal

HI Pascal, could you please post the script or send to me by email? I am not able to open the link.

Thanks,

Abraham

Hi Abraham, I’m happy to, and I will, but what happens when you click the link in my post above? Anything? It seems to work OK here. How about right-click and ‘Save link as’ ?
Ah, you’re in China…
-Pascal

Hi @pascal,
Script works perfectly. Thanks for your help!
-Abraham