Alua-Kinzhebayeva / iOS-PDF-Reader

PDF Reader for iOS written in Swift
MIT License
533 stars 150 forks source link

PDF doesn't appear in the right direction #41

Closed vipinjohney closed 7 years ago

vipinjohney commented 7 years ago

PDF is not flipped to the right direction.

The below code is not working. // Flip the context so that the PDF page is rendered right side up. con.translateBy(x: 0, y: bounds.size.height) con.scaleBy(x: 1, y: -1)

I think you need to add "concatenate" - context.concatenate(_ transform: CGAffineTransform)

ranunez commented 7 years ago

Can you please provide a screenshot or even better a PDF that exhibits this bug so we can properly test and fix it? Feel free to send in a pull request as well!

ranunez commented 7 years ago

Closing due to inactivity, feel free to re-open if you have an example.

vipinjohney commented 7 years ago

Any PDF which has content in the landscape mode should produce this bug. simulator screen shot 07-mar-2017 2 43 35 pm

ranunez commented 7 years ago

I seem I cannot reproduce this. I tried loading up a random PDF that has its content in landscape mode, but I am unable to reproduce this issue (screenshots attached). Are you running on HEAD or an older commit? simulator screen shot mar 7 2017 7 21 04 am simulator screen shot mar 7 2017 7 26 10 am

vipinjohney commented 7 years ago

First Floor Plan.pdf

Try with this document.

ranunez commented 7 years ago

@vipinjohney This should be fixed in v2.2.2