iOS Annotation List Scrolling

48 views
Skip to first unread message

David Compton

unread,
May 23, 2017, 11:33:53 AM5/23/17
to PDFTron WebViewer
We are having trouble with scrolling of the annotations list on an iPad when the list of annotations exceeds the screen height.

The problems (which are inconsistent) are:
  1. Sometimes you cannot scroll to the bottom of the list.
  2. Sometimes the scrolling does not work at all - the tap and drag drags the whole viewer up or down, revealing some white space and then it just pops back to its original position.

We have the following customizations in readerControlCustomConfig:

// Hide the Save Annotations button from the web viewer settings page
$('#saveAnnotationsBtn').parent().hide();
// Hide the Annotations / Bookmarks toggle buttons
$('.annotBookmarkToggleGroup').remove();


Actually with a bit more testing I think that the problems seem to be related to changing orientation - and only seem to affect the app in landscape mode.  I can consistently reproduce the problem as follows:

  1. Have document with a list of annotations that exceeds the page height.
  2. Open it in landscape mode and view the list of annotations - scrolling should work fine.
  3. Rotate to portrait mode - again scrolling in the list of annotations works fine.
  4. Rotate back to landscape mode and view the list of annotations - at this point the first attempt to scroll will not allow you to scroll to the bottom of the list (problem 1 above), the second attempt to scroll will have the affect of dragging the entire viewer (problem 2 above).
  5. The other thing that I notice at this point is that the document in the viewer, which previously filled the viewer now has been pushed down so it goes off the bottom of the screen.  There is no way to see the lower part of the document and there is some blank space up above the document.

Is there something that I need to be doing to handle the orientation changes to avoid these issues?


Kind regards,


David


Regards,

David

Justin Jung

unread,
May 23, 2017, 6:58:44 PM5/23/17
to PDFTron WebViewer on behalf of David Compton
We are having trouble reproducing the issue. We tested on an iPad mini 2 version 10.2.1.
What device and version did you test on?

Justin Jung
Software Developer
PDFTron Systems Inc.

David Compton

unread,
May 24, 2017, 11:33:14 AM5/24/17
to PDFTron WebViewer on behalf of Justin Jung
Hi Justin,

I experience the problem on 2 different iPad Pros (9.7 inch screen). iOS version 10.3.2.

Kind regards,

David

--
You received this message because you are subscribed to the Google Groups "PDFTron WebViewer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pdfnet-webviewer+unsubscribe@googlegroups.com.
To post to this group, send email to pdfnet-webviewer@googlegroups.com.
Visit this group at https://groups.google.com/group/pdfnet-webviewer.
For more options, visit https://groups.google.com/d/optout.

Justin Jung

unread,
May 25, 2017, 3:27:20 PM5/25/17
to PDFTron WebViewer on behalf of David Compton
We tried testing with iPad Mini, iOS version 10.3.2, but unfortunately we couldn't reproduce the issue.
Are you able to reproduce the issue in other iOS devices besides the iPad Pro?

David Compton

unread,
May 31, 2017, 7:29:12 PM5/31/17
to PDFTron WebViewer
Yes I can also reproduce it on an iPad Air 2.

Justin Jung

unread,
Jun 2, 2017, 1:59:43 AM6/2/17
to PDFTron WebViewer on behalf of David Compton
We are still having trouble reproducing the error.
Would you be able to send us a sample project including the document and the annotations that you used to reproduce the issue?
This will help us get as close as possible to the setup that you are using.

Volker Andres

unread,
Jun 8, 2017, 11:51:32 AM6/8/17
to PDFTron WebViewer
Hi,

We have a similar bug, easy to reproduce and probably related. Latest iOS, iPad Pro, UIWebview, Cordova/Ionic project.
  1. create a lot of annotations so that you have to scroll
  2. scroll to the last annotation and try to edit it
  3. the list is now white - in the DOM you can see the form at the top, but the "list" is still scrolled at the bottom


Best Regards,

Volker

Justin Jung

unread,
Jun 9, 2017, 8:06:32 PM6/9/17
to PDFTron WebViewer on behalf of Volker Andres
Hello,

Thanks for the steps to reproduce. Looks like this is only reproducible in Cordova apps.
As a work around, you can add the following line in MobileReaderControl.js in the editAnnotationNote function.

    // if we don't focus with a delay in IE then the keyboard is shown
    // but for some reason the cursor isn't in the textarea so you can't start typing
    setTimeout(function() {
        $textarea.focus();
    }, 100);
} else {
    $textarea.focus();
    // ADD THIS LINE
    $('#annotationDialogCloseButton')[0].scrollIntoView();
}

This forces the close button top right corner to be scrolled into view, which makes sure everything is in view.

David Compton

unread,
Jun 19, 2017, 1:08:53 PM6/19/17
to PDFTron WebViewer on behalf of Justin Jung
The problem that I reported seems to be fixed in version 3.0.

--

Justin Jung

unread,
Jun 20, 2017, 7:01:15 PM6/20/17
to PDFTron WebViewer on behalf of David Compton
That's great to hear! Thanks for letting us know :)
Reply all
Reply to author
Forward
0 new messages