cleanup menu drawing code changes from @Larz0 and other whitespace fixes