|
|
PdfRenderer always respects the PDF page box, so those “borders” are usually baked into the file by Word. Zero padding won’t help. Either export the PDF with zero margins in Word, or crop the page using the PDF crop box (iText/PdfBox). In code, render into a bitmap scaled to your view with a Matrix to fill the screen.
|
|
|
Hello, Winforms: The page border is always displayed outside of its area. So the following will help you achieve your goal. Code:this.SizeMode = SizeModes.FitToWidth;
this.ShowCurrentPageHighlight = false;
this.PageMargin = new Padding(0);
this.Padding = new Padding(0);
WPF: Code:this.SizeMode = SizeModes.FitToWidth;
this.ShowCurrentPageHighlight = false;
this.PageMargin = new System.Windows.Thickness(0);
this.Padding = new System.Windows.Thickness(0);
this.PageBorderColor = Colors.White;
|
|
|
I'm developing a program to display my sheet music on a Windows tablet (Microsoft Surface). The PDFs contain only one page, and I generate them myself using Word. The issue is that when viewing the PDF in full screen using PdfRenderer, it does not completely fill the display. The PDF page is rendered with page borders, and around the rendered page, there is additional empty space, making the PDF content appear smaller than the available display space. I want to make full use of the display by eliminating both the page border and the extra empty space that appears around it. I have tried setting Padding and Margin to zero, but that does not solve the problem. How can I achieve this? I have attached an image showing the top part of the screen as it currently displays the PDF.  Thanks!
|
Important Information:
The Patagames Software Support Forum uses cookies. By continuing to browse this site, you are agreeing to our use of cookies.
More Details
Close