Douwe Siegersma Member Licensed User Longtime User Feb 21, 2022 #1 Hello, I'm using PDFView2 (PDFium) to load and show a PDF file. I want to draw lines on it by using a canvas but this doesn't work. B4X: Canvas1.Initialize(PDFView1) C.DrawLine(100,100,100,500,Colors.Red,5) Activity.Invalidate
Hello, I'm using PDFView2 (PDFium) to load and show a PDF file. I want to draw lines on it by using a canvas but this doesn't work. B4X: Canvas1.Initialize(PDFView1) C.DrawLine(100,100,100,500,Colors.Red,5) Activity.Invalidate
DonManfred Expert Licensed User Longtime User Feb 21, 2022 #2 PDFView2 is not a view you can use on a Canvas. You can export any page to an Bitmap and draw this Bitmap on a canvas and then draw lines on this. Upvote 0
PDFView2 is not a view you can use on a Canvas. You can export any page to an Bitmap and draw this Bitmap on a canvas and then draw lines on this.
Douwe Siegersma Member Licensed User Longtime User Feb 21, 2022 #3 Hello, Thank you for your quick reply. The PDF contains only one page. How do I export this page to a bitmap? Best regards, Douwe Upvote 0
Hello, Thank you for your quick reply. The PDF contains only one page. How do I export this page to a bitmap? Best regards, Douwe
DonManfred Expert Licensed User Longtime User Feb 21, 2022 #4 renderPageBitmap or renderPageBitmap2 Upvote 1
Douwe Siegersma Member Licensed User Longtime User Feb 22, 2022 #5 Ok, thank you. I'll try that. Upvote 0
Douwe Siegersma Member Licensed User Longtime User Feb 22, 2022 #6 Thank you DonManfred, it works fine for me now! Best regards, Douwe Upvote 0