-
-
Notifications
You must be signed in to change notification settings - Fork 531
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's probably not going to be merged as the owner doesn't seem to be active on this package.
However, there is no point to multiply by 1, if window.devicePixelRatio is creating problems you might just remove the multiplication.
so instead of * 1 you just write:
var scale = canvasElt.offsetWidth / pdfPage.getViewport({ scale: 1 }).width
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your input. I did try this originally and it didn't always fix the issue in some edge cases. 1 is the second condition, it multiplies by window.devicePixelRatio if the relevant condition is met.
andorfermichael
commented
Sep 16, 2021
@FranckFreiburger would be really great if this issue would be fixed.
Uh oh!
There was an error while loading. Please reload this page.
Set ratio to 1. Any other value causes unexpected alignment issues of the annotation layer, specifically some instances in windows 10 google chrome. Tested on multiple devices, this fix has no issues.