Print Page | Close Window

PDFLibrary SetTextColor to Black

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=2898
Printed Date: 28 Jun 25 at 1:40PM
Software Version: Web Wiz Forums 11.01 - http://www.webwizforums.com


Topic: PDFLibrary SetTextColor to Black
Posted By: ebassador
Subject: PDFLibrary SetTextColor to Black
Date Posted: 16 May 14 at 6:05PM
I used SetTextColor(1,0,0) to change to RED text.  It work fine.  Now, on the same document, I want to switch back to BLACK.  SetTextColor(1,1,1) doesn't work.  It gives me white (invisible) color instead. OuchShocked



Replies:
Posted By: ebassador
Date Posted: 16 May 14 at 6:53PM
I tried something counter intuitive to me: SetTextColor(0,0,0).  It is how you choose BLACK.  Problem resolved.


Posted By: AndrewC
Date Posted: 18 May 14 at 9:39AM
The 3 values are RGB values between 0 and 1.  Other libraries use a range of 0 and 255.

 0,0,0 = Black  (0% red, 0% green, 0% blue)
 1,1,1 = White  (100% red, 100% green, 100% blue)
 1,0,0 = Red    (100% red, 0% green, 0% blue)

Andrew.




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