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!
Bold truetype font |
Post Reply |
Author | |
skwirelboy
Team Player Joined: 27 Feb 06 Status: Offline Points: 45 |
Post Options
Thanks(0)
Posted: 16 Dec 08 at 7:05AM |
I can see how to make aerial, courier and times bold. You just add different fonts. How do you make text bold for other truetype fonts added via AddTrueTypeFont function?
Thanks
|
|
DELBEKE
Debenu Quick PDF Library Expert Joined: 31 Oct 05 Location: France Status: Offline Points: 151 |
Post Options
Thanks(0)
|
Try to used SetFontFlags(0,0,0,0,0,0,0,1) after loading the font
|
|
skwirelboy
Team Player Joined: 27 Feb 06 Status: Offline Points: 45 |
Post Options
Thanks(0)
|
Hi Delbeke,
I have tried this, but I get no difference with the font whatsover when I call SetFontFlags.
Below is the code:
index:=QP.AddTrueTypeFont('Tw Cen MT', 1);
if index=0 then begin Showmessage('couldnt add font'); exit; end; Qp.SelectFont(index);
index:=QP.SetFontFlags(0, 0, 0, 0, 0, 0, 0, 1); if index<>1 then begin Showmessage('couldnt set Flags'); exit; end; QP.DrawText(10, 10, 'hello'); I get no messages back.
Any ideas?
BTW should setFontFlags work in the same way for the standard fonts or do I need to continue to add their various forms for bold and italic?
Thanks
Mark
|
|
skwirelboy
Team Player Joined: 27 Feb 06 Status: Offline Points: 45 |
Post Options
Thanks(0)
|
Have discovered thanks to Ingo that SetFontFlags is not the way to do this. For truetype fonts you simply add eg [Bold] or [BoldItalic] at the end of the font name when calling AddTrueTypeFont. Works like a treat and was covered perfectly well in the help for AddTrueTypeFont if only I had read it. Regards
Mark
|
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |
Copyright © 2017 Debenu. Debenu Quick PDF Library is a PDF SDK. All rights reserved. About — Contact — Blog — Support — Online Store