简体   繁体   中英

pdf.js start from the bottom of the document

We are making an implementation that will change to the previous document when roll up to the start of current document.

I would like, in that case, to start from the bottom of the document. Its not hard to accomplish from inside the code (viewer.js), but I wouldn't like to change the original code from pdf.js so would make easier to update when needed.

Is there anyway to accomplish that, without changing the code from viewer.js?

In function scrollIntoView(element, spot) of viewer.js, we did for now this:

if(window.parent.PDFStartBottom){
      parent.scrollTop = parent.scrollHeight - element.offsetTop - parent.clientHeight;
      return;
  }

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM