PDF file is hiding under Navigation Controller

30 views
Skip to first unread message

Sipho Koza

unread,
Jan 19, 2016, 12:51:18 PM1/19/16
to PDFTron PDFNet SDK
Good day

I'm developing an iOS Pdf app using pdftron framework.

My problem is: When displaying a pdf in a viewController is hiding about a height of a navigationController (44 pixels) under the navigationController, and it animates after like a second a pdf file is displayed, even if you try and scroll down the pdf file, it animates the same..hide under the navigationController.

My code for the frame for displaying the pdf:

PTPDFViewCtrl *_pdfViewCtrl = [[PTPDFViewCtrl alloc] initWithFrame:[self.view bounds]];


I also tried this

_pdfViewCtrl = [[PTPDFViewCtrl alloc] initWithFrame:CGRectMake(0, 50, self.view.frame.size.width, self.view.frame.size.height)];

Thank you.

James

unread,
Jan 19, 2016, 8:05:44 PM1/19/16
to PDFTron PDFNet SDK
Hi Sipho,

I did a quick Google search, and found the following question/answer on Stack Overflow that appears to answer your question: http://stackoverflow.com/questions/18924431/ios-7-navigationcontroller-is-setting-the-contentinset-and-contentoffset-of-m

Please let me know if it helps.


Sipho Koza

unread,
Jan 21, 2016, 1:41:29 PM1/21/16
to PDFTron PDFNet SDK
Thank you, actually you gave me a clue. I unchecked the "Under Top Bars" check box on the side bar and it worked. Thank you.
Reply all
Reply to author
Forward
0 new messages