fixed rounding issues while drawing