logo
Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Post a reply
From:
Message:

Maximum number of characters in each post is: 32767
Bold Italic Underline   Highlight Quote Choose Language for Syntax Highlighting Insert Image Insert an existing Attachment or upload a new File... Create Link   Unordered List Ordered List   Left Justify Center Justify Right Justify   Outdent Indent   More BBCode Tags
Font Color Font Size
Security Image:
Enter The Letters From The Security Image:
  Preview Post Cancel

Last 10 Posts (In reverse order)
Guest Posted: Tuesday, January 12, 2016 5:10:25 AM(UTC)
 
thanks a lot !!
Nwp Posted: Tuesday, January 12, 2016 2:38:16 AM(UTC)
 
Well... for example ... set the background color for the PdfView control, and then change the color for all objects on the page. The sample code below:

Code:
pdfView1.PdfBackColor = Color.Black;
var page = pdfView1.Document.Pages[pdfView1.CurrentPage];
foreach( var obj in page.PageObjects)
{
    if (obj is PdfPathObject)
    {
        obj.StrokeColor = Color.Green;
        obj.FillColor = Color.Black;
    }
    else
        obj.FillColor = Color.Green;
}


Before and after
before
Guest Posted: Tuesday, January 12, 2016 2:01:09 AM(UTC)
 
ok thanks and how can i do that with my viewer for entire document please ?
nwp Posted: Tuesday, January 12, 2016 1:11:13 AM(UTC)
 
Hi
you can change it for viewing, but you can't save it into pdf document

Loo at FillColor and StrokeColor properties here: http://pdfium.patagames.com/help/html/459da43b-c4ab-147f-3131-6e4341e95214.htm
Guest Posted: Monday, January 11, 2016 11:33:36 PM(UTC)
 
Hi everyone,

Is it possible to change the color of pdf content ?

Thank you