Shatner's rug for STAR TREK 4 was well-glued down, when he went to $ave the whales, that's for sure. But, when he first submerged into the water, the camera's view of him is blocked, so that we don't see how unnaturally the rug changes, when it takes on water ... the adjustment. Then, when he swims around, it's already waterlogged, and is allowed to behave like real hair, by that point. But, when The Shat breaks the surface, he'll be damned if he'll wipe the hair out of his face and end up displacing it.
From STAR TREK 2 through 5, his hairpiece looked like a helmet of pubic hair. It was never a complimentary look for the aging actor, drawing attention to itself. But in STAR TREK: The Motion Picture, he really lookled the part of a Starfleet Captain. It's almost hard to believe he's pushing 50, he looks like he's ready for adventure! Having, seemingly, recognised this, the studio sprung for the best rug William Shatner has ever sported, in his life. At times, it even threatens to look natural. But the days of wearing the TOS hairpiece were long over, even then ...