voghDev/PdfViewPager

Continuous scrolling of pages

abhinavtestbook opened this issue · 3 comments

Hey , I want to have continuous scrolling of pdf page instead of one by one swipe. As sometimes PDF's contain more than 20 pages , and if we want to go to page no. 15 directly ,its a pain to swipe pages one by one.
Any such feature exists ?
P.S. Using VerticalViewPager.

Hi,

This is not internally supported in the library. As its name says, the ViewPager widget itself is made to be navigated by swiping, so this requirement would only make sense with a different widget rather than a ViewPager.
In the past I tried to implement a PdfRecyclerView which implemented continous scrolling of a Pdf document. It was quite inefficient in terms of rendering, and caused many memory issues. I cancelled the library because it was basically crap 😄

In order to meet your requirements, I would paint a Custom View on top of the PdfViewPager that implements some sort of "fast scrolling" (a very common UI pattern), so when user drags and drops to a specific page, you can change directly to the mentioned page with a single swipe, instead of going one by one :-)

Hope it helps

Do you have plans to paint a Custom View in near future ? It would be a nice user experience.

Not for this library, should be a responsibility for each app to implement fast scrolling in the desired way, and handle its own custom views :)