PDFsharp & MigraDoc Foundation

PDFsharp - A .NET library for processing PDF & MigraDoc Foundation - Creating documents on the fly
It is currently Thu Mar 28, 2024 1:33 pm

All times are UTC


Forum rules


Please read this before posting on this forum: Forum Rules



Post new topic Reply to topic  [ 6 posts ] 
Author Message
PostPosted: Fri Mar 30, 2007 6:21 am 
Offline

Joined: Fri Mar 30, 2007 6:12 am
Posts: 1
Hi,

I have a PDF document with some jpg images. I want to add some content/text to this PDF document. But this content/text should not be visible when the PDF document is being viewed.

I want to add this content so that the document search lists this PDF when searched for the keywords in the content.

Can any one please tell me how can i do this....

Regards,

Pradeep


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed May 21, 2008 11:54 am 
Offline

Joined: Wed May 21, 2008 10:52 am
Posts: 3
Hi!

I would also be interested in a solution for this problem.

Tx.


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed May 21, 2008 4:07 pm 
Offline

Joined: Wed May 21, 2008 3:59 pm
Posts: 7
Have you tried placing the text outside the boundaries of the page?

For Example,

Code:
            XPoint t = new XPoint(page.Width, page.Height)));
            gfx.DrawString("Offpage",new XFont("Verdana",10), XBrushes.Black, t);


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed May 21, 2008 5:47 pm 
Offline

Joined: Wed May 21, 2008 10:52 am
Posts: 3
AlbinoTux wrote:
Have you tried placing the text outside the boundaries of the page?

For Example,

Code:
            XPoint t = new XPoint(page.Width, page.Height)));
            gfx.DrawString("Offpage",new XFont("Verdana",10), XBrushes.Black, t);


You're almost there. :-)
Point is - if and when a user searches text within the document (using adobe Reader's search), Reader should position the view to the word it found. So, the word that was found would be selected, but words around it would not be visible since it would be 'behind' the image.


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed May 21, 2008 5:52 pm 
Offline

Joined: Wed May 21, 2008 3:59 pm
Posts: 7
Try a brush that is completely transparent?

Code:
            XColor bg = XColors.DarkGray;
            bg.A = 0.0;
            XSolidBrush br = new XSolidBrush(bg);

            XPoint t = new XPoint(0, 0)));
            gfx.DrawString("Offpage",new XFont("Verdana",10), br, t);


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed May 21, 2008 6:42 pm 
Offline

Joined: Wed May 21, 2008 10:52 am
Posts: 3
AlbinoTux wrote:
Try a brush that is completely transparent?

Code:
            XColor bg = XColors.DarkGray;
            bg.A = 0.0;
            XSolidBrush br = new XSolidBrush(bg);

            XPoint t = new XPoint(0, 0)));
            gfx.DrawString("Offpage",new XFont("Verdana",10), br, t);


Ok, I will try this. I'll let you know how it went...
Thanx.


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 6 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 136 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Privacy Policy, Data Protection Declaration, Impressum
Powered by phpBB® Forum Software © phpBB Group