more drawing refactoring