1
0
Fork 0
mirror of https://github.com/mozilla/pdf.js.git synced 2025-04-20 15:18:08 +02:00

Add Util functions to PDFJS.

This commit is contained in:
Brendan Dahl 2012-04-16 09:45:49 -07:00
parent 459e08d1b4
commit 04c8d1454d
2 changed files with 2 additions and 2 deletions

View file

@ -787,7 +787,7 @@ var PageView = function pageView(container, pdfPage, id, scale,
}
function createElementWithStyle(tagName, item) {
var rect = viewport.convertToViewportRectangle(item.rect);
rect = Util.normalizeRect(rect);
rect = PDFJS.Util.normalizeRect(rect);
var element = document.createElement(tagName);
element.style.left = Math.floor(rect[0]) + 'px';
element.style.top = Math.floor(rect[1]) + 'px';