code cleanups to tabs drawing