minor drawing related refactoring