Microsoft Windows Phone 8.1 support ends (13 Jul 2017)

Microsoft has ended support for Windows Phone 8.1

Questions about Android development and PDF

PDF display goes blank while pinch-zooming

More
IP: 75.164.154.125 2 years 7 months ago #15813 by arlomedia
When I pinch-zoom a PDF document to resize it, the display goes blank as soon as the pinch gesture is recognized, and it doesn't reappear until I remove my fingers from the screen. When the document reappears, it has resized correctly, but it's difficult to pinch to the desired size while the document is hidden, and this makes my app look clunky and not polished.

I tried the PDFSample app that comes with the SDK download, and it resizes smoothly with no problems. But I can't figure out what is different in my setup.

I have updated to the latest SDK version 3.65.27. I've tested my app on Android 5, 8 and 12 and the behavior is the same on all three. I am not using the PDFViewAct class like the sample app does because I'm placing the PDF viewer directly into my view hierarchy. Here is my basic code:
Code:
    this.pdfView = PDFLayoutView(this.fragment.activity, null)     val pdfDocument = Document()     val path = this.directory + this.name + " - " + this.id + "." + this.format     val error = pdfDocument.Open(path, null)     if (error == 0) {         Global.g_view_mode = 0         this.pdfView.PDFOpen(pdfDocument, this)     }     this.contentView.addView(this.pdfView)

Has anyone seen this behavior and know what to do about it?
Time to create page: 0.398 seconds
Powered by Kunena Forum