helping graphics2d implementation