Print Page | Close Window

how to do something like the example ?

Printed From: Debenu Quick PDF Library - PDF SDK Community Forum
Category: For Users of the Library
Forum Name: I need help - I can help
Forum Description: Problems and solutions while programming with the Debenu Quick PDF Library and Debenu PDF Viewer SDK
URL: http://www.quickpdf.org/forum/forum_posts.asp?TID=2080
Printed Date: 15 Apr 26 at 5:15AM
Software Version: Web Wiz Forums 11.01 - http://www.webwizforums.com


Topic: how to do something like the example ?
Posted By: m_alam
Subject: how to do something like the example ?
Date Posted: 26 Dec 11 at 12:45PM
hi, greetings everyone..


please checkout the following image :



how to do some thing like that in QucikPDF library?

it's called watermark.

i like to place that text "DEMO" and Hyperlink "www.yoursite.com" on top of each/any page.. and when use click on the link, it will visit that link ?

i hope clear? any one can help me out?

best regards
kamrul hassan




Replies:
Posted By: Ingo
Date Posted: 26 Dec 11 at 1:24PM
Hi!

Go to the samples section and search for "watermark" in the topics.
I've put a sample there a long time ago:
http://www.quickpdf.org/forum/watermark_topic230.html

Cheers, Ingo


Posted By: AndrewC
Date Posted: 27 Dec 11 at 1:18AM

I had a bit of a play with the following code.  It seems the Acrobat and Nitro automatically pick up the web address as a web link so this code will do what you require.

Andrew.

            QP.LoadFromFile("unstamped.pdf", "");

            int fid = QP.AddStandardFont(4);      // Helvetica    

            double angle = 30;

            for (int p = 1; p <= QP.PageCount(); p++) /* Loop through all pages in doc */
            {
                QP.SelectPage(p);

                QP.SetOrigin(1);            // Top left
                QP.SetMeasurementUnits(0);  // Points

                QP.SelectFont(fid);
                QP.SetTextAlign(1);         // Align text center

                QP.SetTextSize(72);
                QP.SetTextColor(0, 0, 1);
                QP.DrawRotatedText(QP.PageWidth() / 2, QP.PageHeight() / 2, angle, "www.debenu.com"); // Draw Watermark at center

                QP.SetTextSize(132);
                QP.SetTextColor(1, 0, 0);
                QP.DrawRotatedText(QP.PageWidth() / 2, QP.PageHeight() / 2 - 80, angle, "DEMO"); // Draw Watermark at center
        }
        QP.SaveToFile("stamped.pdf");



Print Page | Close Window

Forum Software by Web Wiz Forums® version 11.01 - http://www.webwizforums.com
Copyright ©2001-2014 Web Wiz Ltd. - http://www.webwiz.co.uk