Back in V5 Pascal kindly made “Hide” and “Show last” Python scripts for me which gave me Sketchup functions that helped my transition to Rhino.
_-RunPythonScript “C:…\8.0\scripts\samples\HideSpecial.py”
_-RunPythonScript “C:…\8.0\scripts\samples\ShowSpecial.py”
I’ve been using them ever since. However, I’m on RH8 now and thought those two commands probably exist somewhere.
I realize the Standard _Hide command can replace the HideSpecial script. However, I can find no native “show last hidden” command. But now my “Show Last” script is no longer working. I have the script mapped to the “K” key, but now I get this result when I try to run it.
Command: _-RunPythonScript
Python Script <s"C\Users\xxxxx\AppData\Roaming\McNeel\Rhinoceros\8.0\scripts\samples\ShowSpecial.py"
I don’t know if the ShowSpecial script references the objects from the HideSpecial script which is why I doesn’t work. Perhaps Pascal can answer at some point.
Is there a native “show last” command I can map to a single key stroke?
when you use -Hide with the dash in front, it allows you to set a name for the object to hide,
-Show with the name entered will then show this object again making 2 macros for this naming it “last” should be fairly easy
1 Like
Thanks for the quick response.
Pardon my ignorance, would this mean I’d have to name each object I hide?
no not at all. once you show these objects the name gets deleted from the list again so you can then hide any other object(st) the same way with the following macros
-hide pause last enter enter
-show last enter
assign them to an alias or shortcut if you use that regularly. (copy the entire macro into the alias function for instance)
you can of course change the word “last” to your likings “1” or “a” or whatever you can make as many as you want if you need that in several steps, instances.
there is also a command called Isolate and Unisolate when you want show only one object you are working on sending the rest into outer space.
Thanks for your help. However, I tried this but it does not give me what I’m looking for.
I made two aliases.
H -Hide pause last enter enter
K -Show last enter
I have four objects if I hide one, then another, then a third leaving the fourth. My “show last” (K) should only bring back the third so I only have the third and fourth. However, this brings back all three hidden objects. Perhaps my syntax is wrong? Should the be a ! ’ or _ somewhere in there?
that sounds more difficult to achieve. lets start from the beginning you mentioned 2 py scripts above but you only posted a link not the scripts, maybe they can be adapted by someone for v8
the syntax is ok from how i see it, !
is i believe only used if you want all other commands to exit before this macro starts but i am not a macro pro, still i am rather sure it is not needed here, anyway hiding stuff continuously and just showing the last is definitely not anything you can achieve with any regular commands.
if nothing else works you can also make the macro stop at the naming process and then enter 1,2,3,4 in sequence and then shows these numbers, though that is surely less convenient. you also have a toolbar that indicates these functions with a prepared set of 3 to show and hide
what are you actually doing that needs such an intricate show hide ensemble anyway if i may ask?
Thanks again. The “unhide last” is something that is very useful in my workflow and I’ve been using it forever. It’s great for rotating around a four wall room and hiding a wall to see inside then unhiding for the next view which needs to have that last hidden wall but does not need all the other hidden objects.
The scripts worked in V8, however, I found a big lag in the processing unlike in V7. I figured I could replace the hide python script with the build-in “hide” command to speed things up. But after doing that the “Show last” script stopped working and all became kaput. I have just redone the Aliases again to use Pascal’s scripts and they work once more. The initial run still has a lag that seems like the time it takes to fire up the “_-RunPythonScript” part of the process.
Here are the scripts Pascal wrote.
HideSpecial.py (270 Bytes)
ShowSpecial.py (416 Bytes)
Hi @CalypsoArt
In V8 as in V7 you need to use both scripts you supplied for the hide special to work.
What the scripts do is:
HideSpecial lets the user select objects to be hidden and adds an object tag to them.
ShowSpecial selects the objects that were tagged by the hide special command.
So you need to run the hidespecial script for the show special script to work. Showspecial can’t work with regular Rhino hide because Rhino hide does not add any tags to objects.
I don’t have v8 so I can’t speak for the speed issue. Perhaps for a fix you could try to remove the scripts and their aliases exit rhino and restart, then exit and restart rhino again and add both scripts.
RM
Thanks for the explanation. I kinda figured they must need to work together, but did not understand why.