Do you own a Debenu Quick PDF Library version 7, 8, 9, 10, 11, 12, 13 or iSEDQuickPDF license? Upgrade to Debenu Quick PDF Library 14 today!

Debenu Quick PDF Library - PDF SDK Community Forum Homepage
Forum Home Forum Home > For Users of the Library > I need help - I can help
  New Posts New Posts RSS Feed - DrawHTMLTextBox - issue with non breaking space
  FAQ FAQ  Forum Search   Register Register  Login Login

DrawHTMLTextBox - issue with non breaking space

 Post Reply Post Reply
Author
Message
MarcoFischer View Drop Down
Beginner
Beginner


Joined: 29 Apr 15
Location: Deutschland
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote MarcoFischer Quote  Post ReplyReply Direct Link To This Post Topic: DrawHTMLTextBox - issue with non breaking space
    Posted: 04 May 15 at 6:46PM
Hello,

see the following example for this issue:


To hold the number and the name together, i use non breaking spaces ( ) between the number and the name parts. Only in front of the next number i use a simple blank to get a line break if nessessary.

... 5 Edith Gloxin; 6 Horst "Hottel" Morgenroth; ...

This works perfect without any HTML formatting.

By using HTML formatting the following non breaking space don't work:

... <B>5</B>&nbsp;Edith&nbsp;Gloxin; <B>6</B>&nbsp;Horst&nbsp;"Hottel"&nbsp;Morgenroth; ...
OR
... <B>5&nbsp;</B>Edith&nbsp;Gloxin; <B>6&nbsp;</B>Horst&nbsp;"Hottel"&nbsp;Morgenroth; ...

I know, &nbsp; are not supported according to "Appendix A - Supported HTML tags", but it works perfect until there is a html tag before or after the non breaking space.

Are there any other solutions to control line breaking?

Thanks for any information.

Best regards

Marco
Back to Top
erico View Drop Down
Senior Member
Senior Member
Avatar

Joined: 24 Sep 14
Location: Minnesota USA
Status: Offline
Points: 51
Post Options Post Options   Thanks (0) Thanks(0)   Quote erico Quote  Post ReplyReply Direct Link To This Post Posted: 05 May 15 at 4:28PM
It appears that the HTML tags are being recognized as word break locations.

You may need to preemptively handle the line breaking by measuring the text before adding it. Look at GetHTMLTextWidth() for this. Combine as many names/numbers as will fit on one line, then force a line break before the next number.
Eric O
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 11.01
Copyright ©2001-2014 Web Wiz Ltd.

Copyright © 2017 Debenu. Debenu Quick PDF Library is a PDF SDK. All rights reserved. AboutContactBlogSupportOnline Store