factored common functionality to core and drawing components