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 - Bold truetype font
  FAQ FAQ  Forum Search   Register Register  Login Login

Bold truetype font

 Post Reply Post Reply
Author
Message
skwirelboy View Drop Down
Team Player
Team Player


Joined: 27 Feb 06
Status: Offline
Points: 45
Post Options Post Options   Thanks (0) Thanks(0)   Quote skwirelboy Quote  Post ReplyReply Direct Link To This Post Topic: Bold truetype font
    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
Back to Top
DELBEKE View Drop Down
Debenu Quick PDF Library Expert
Debenu Quick PDF Library Expert
Avatar

Joined: 31 Oct 05
Location: France
Status: Offline
Points: 151
Post Options Post Options   Thanks (0) Thanks(0)   Quote DELBEKE Quote  Post ReplyReply Direct Link To This Post Posted: 17 Dec 08 at 12:53PM
Try to used SetFontFlags(0,0,0,0,0,0,0,1) after loading the font
Back to Top
skwirelboy View Drop Down
Team Player
Team Player


Joined: 27 Feb 06
Status: Offline
Points: 45
Post Options Post Options   Thanks (0) Thanks(0)   Quote skwirelboy Quote  Post ReplyReply Direct Link To This Post Posted: 20 Dec 08 at 4:27AM
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
Back to Top
skwirelboy View Drop Down
Team Player
Team Player


Joined: 27 Feb 06
Status: Offline
Points: 45
Post Options Post Options   Thanks (0) Thanks(0)   Quote skwirelboy Quote  Post ReplyReply Direct Link To This Post Posted: 04 Feb 09 at 7:54AM

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
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