Refactored pdf writer scale methods