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!
get/set standard fonts in the pdf |
Post Reply |
Author | |
toran
Beginner Joined: 20 Feb 12 Status: Offline Points: 14 |
Post Options
Thanks(0)
Posted: 30 Apr 12 at 2:56AM |
I have couple of questions related to font handling. Q#1: I am unsure how to identify the standard fonts in existing pdf documentMy pseudocode looks lik this: (c#) selectDocument(mydocid); int iFontCount = FindFonts(); for (int i = 1; i <= iFontCount; ++i) { int fontid = getFontId(i) selectFont(fontid); // here I would like to know if the the font that I just selected belongs to the // standard font as they are described in "AddStandardFont" function // ? } Q#2: following two lines in respect to the same selected document int fid1 = AddStandardFont(4); int fid4 = AddStandardFont(4); produce two different font ids. I would expect that subsequent addition of a standard font should return the id of the previously added font. Am I wong here? Thanks
Edited by toran - 30 Apr 12 at 3:29AM |
|
Ingo
Moderator Group Joined: 29 Oct 05 Status: Offline Points: 3524 |
Post Options
Thanks(0)
|
Hi Toran!
Before the loop you have to call ONE TIME FindFonts to get all used fonts. The next step is FontCount for your loop. With GetFontID you'll get the ID of the selected font in your loop. With FontName and (for example) FontType you'll get name and type of the selected font in your loop. Here you'll find all font-related functions: http://www.quickpdflibrary.com/help/quickpdf/Fonts.php Cheers, Ingo |
|
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