BIG viewport - let's get all the code!
Refactorings and improvements