Home Technical Talk

Maya Alt+H (Hide Unselected) Not Working

polycounter lvl 7
Offline / Send Message
neverwander polycounter lvl 7
Hey guys, hoping you can help me out with this. Been having a problem where pressing Alt+H to hide all unselected items no longer works. Ctrl+H (hide selected) and Ctrl+Shift+H (unhide last hidden object) still work.

FYI using Maya 2013 in Windows 7 64-bit. I've tried resetting my preferences and reinstalling Maya, but neither worked. Any ideas?

Replies

  • neverwander
    Options
    Offline / Send Message
    neverwander polycounter lvl 7
    I've found the hotkey editor, and set it so Ctrl+u now does it, and that worked. Alt+h was assigned, but still didn't work. Not sure what the heck is going on there. Tried multiple keyboards to see if it was somehow a ghosting issue, but it still didn't work. XP
  • Bartalon
    Options
    Offline / Send Message
    Bartalon polycounter lvl 12
    I was always annoyed with the hotkeys associated with hiding/unhiding objects in Maya, so I wrote a small script to just use Ctrl + H to toggle visibility of selections, as well as unhide the last hidden object if you have no objects selected. With this you can also select multiple hidden and unhidden objects and it will invert the visibility of both groups.
    string $lastHidden[];
    string $hideselect[] = `ls -sl`;
    string $vis[] = { };
    $count = `size $hideselect`; 
    for ($i=0; $i < $count; $i++) { 
          $vis[$i] = ($hideselect[$i] + ".visibility");
          if ( !`getAttr $vis[$i]` ) { 
              setAttr $vis[$i] 1;
         }
         else { 
              setAttr $vis[$i] 0;
              $lastHidden = `ls -sl`;
         }
    } 
    if ( $count == 0 ) { 
         $count = `size $lastHidden`;
         if ( $count != 0 ) { 
              for ($i=0; $i < $count; $i++) { 
                   setAttr ( $lastHidden[$i] + ".visibility" ) 1;
              } 
              select $lastHidden;
         }
         else { print "No previously hidden objects."; }
     }
    
Sign In or Register to comment.