Copy link to clipboard
Copied
Hi,
I am using FontGetdata() function, but this function doesn't give any data.
Which function I need use to get font data.
Please Help me..
Thanks..
Copy link to clipboard
Copied
I don’t know what “FontGetData” is, it’s not part of the Acrobat API set…
What sort of “properties” do you need? IN general, you can use PDDocEnumResources() to get the list of fonts, then use the PDFont APIs to get info about each one.
Copy link to clipboard
Copied
Thank you for your reply..
I need to extract text Font properties like, Font type, Font size from the PDF Page.
Thanks..
Copy link to clipboard
Copied
What do you mean by “font type” exactly? Do you have Acrobat Pro?
Copy link to clipboard
Copied
Thanks for the Reply
I need the Following Font Attributes of the text from the PDF Page.
Font Type-----TrueType or Type1 or Type2 or etc...
Font name----Times New Roman or any other Font
Font Size----8,9,10,etc....
Thanks...
Copy link to clipboard
Copied
I am using PDEFontGetAttrs API to get Font Type and Font Name.
but Font size was not present.
PDEFont pdont = PDETextGetFont(textObject, kPDETextRun, iIndexSubElement);
PDEFontAttrs fontAttrRec;
PDEFontGetAttrs(pdont, &fontAttrRec, sizeof(fontAttrRec));
strcpy_s(fontName, 100, ASAtomGetString(fontAttrRec.name));
CString csfontName = (CString)fontName;
What i need to do to get Font size of the text..
Thanks...
Copy link to clipboard
Copied
Ah, PDEFontGetAttrs not FontGetAttrs. So you are already working in a plug-in.
1. PDEFont has no size. It is just the font, and may be used at any size by PDEText elements.
2. PDEText elements do not have a size either but they have a matrix. You must analyse the matrix and decompose it into scaling, rotation and skewing.
Copy link to clipboard
Copied
Thanks for the Useful Information...