Line painting and grinding machine