path draw moved to new functions