pvginkel / PdfiumViewer

PDF viewer based on Google's PDFium.
Apache License 2.0
967 stars 418 forks source link

Don't change Landscape mode when special situation #33

Closed pablot closed 9 years ago

pablot commented 9 years ago

When some printers are lying about landscape mode vs page sizes we don't want to set PageSettings.Landscape. BROTHER QL-570 and BROTHER QL-580 say that PageSettings Width > Height but Landscape is False. Use your PrintPreview Form and install Brother drivers to check this behaviour.

pvginkel commented 9 years ago

Thank you for your commit. However, your code didn't compile. I've made a similar change to the code base that should handle your scenario.

pablot commented 9 years ago

We will check it little later. Thank's for your support.

It's strange that my code does not compile on your computer. What version of .NET and VS do you use?

pvginkel commented 9 years ago

The problem was that you're referring to the document and currentPage field, but the fields start with an _. In your code the _ was missing.

IanYates commented 9 years ago

Many label printers that print wide labels will have this issue. Zebra drivers have a special checkbox to ignore the portrait/landscape setting coming from the application specifically for this reason - it really helps when printing the results of a Word mail merge. However, I'm yet to see a non-Zebra printer than handles this nicely so it's good to see software handling the condition gracefully.