pdf converter set windows encoding, set imageBehavior, tests refactor