Print Page | Close Window

Drawing Courier font text loses spaces

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=1815
Printed Date: 20 May 25 at 4:22PM
Software Version: Web Wiz Forums 11.01 - http://www.webwizforums.com


Topic: Drawing Courier font text loses spaces
Posted By: Carneno
Subject: Drawing Courier font text loses spaces
Date Posted: 25 Apr 11 at 5:32PM

Hello,

I'm developing a VB 6.0 printing program using QuickPDF Library 7.24.
 
When I DrawWrappedText on a page with a standard Courier font and print the page, the page prints the text, but it loses all the spaces between words.  It only leaves one space between each word.
 
If I draw this text on the page "   1HI          CROYDON         , PA 19021-6997", it prints as    "1HI CROYDON , PA 19021-6997".
 
Does anybody know how to print text on a page as it is including the space characters?
 
Any help would be gratefully appreciated.
 
Thanks,
Tony


-------------
Stop The World, I want To Get Off.



Replies:
Posted By: Rowan
Date Posted: 25 Apr 11 at 10:07PM
Hi Tony,

Extra spaces between words in strings are ignored. If you need to include multiple spaces in your strings then you will need to use the draw HTML text functions (for example DrawHTMLTextBox) and use the HTML space tags (e.g.  ).

Alternatively there is the DrawSpacedText function but it's not possible to selectively use extra spaces with this option.

Cheers,
- Rowan.


Posted By: Carneno
Date Posted: 25 Apr 11 at 10:51PM

Hello Rowan.

Thanks again for helping on yet another issue.
 
I don't think the DrawHTMLTextBox will help.  I would have to count the spaces between words and then fill those spaces with the &nbsp tags.
 
This text is spaced out the way it is so that it overlays a preprinted form without printing over the preprinted areas.
 
I did try the DrawSpacedText and that did not work.
 
Thanks,
Tony


-------------
Stop The World, I want To Get Off.



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