Foxit Developer Blog

    Insights, tutorials, and updates from the Foxit PDF SDK engineering team.

    Foxit PDF SDK 5.3

    How to support non-standard fonts on Foxit PDF SDK?

    To support non-standard fonts on Foxit PDF SDK, follow the steps outlined below: Use the FSCRT_Library_AddFontFile or use FSCRT_Library_SetFontMapperHandler. Create the callback to handle the non-standard font. static FSCRT_FONTMAPPERHANDLER ExternalFontMapper; static FS_RESULT MapExternalFont(FS_LPVOID clientData, FS_LPCSTR fontName, FS_DWORD fontStyles, FS_INT32 weight, FS_INT32 charset, FSCRT_FILE *fontFile, FS_INT32 *faceIndex){ if(fontName=="randomFontName") { //set fontFile to use the non-Standard font [...]

    Read Article
    Foxit PDF SDK 5.3

    How to modify or add additional functionality/methods to the Android C API demo?

    To handle additional functionality or methods to Foxit PDF SDK Android C API demo, follow the steps below: Go to “samplesViewerDemojni” and review how the implementation on how some of the API are already done.Tip: Look for functions that have similar parameters and use it as your template for writing your own. Create a new [...]

    Read Article
    Foxit PDF SDK 5.3

    How to get the text object from a position in a pdf file and change the content of the text object?

    To get text object from a position in a PDF file using Foxit PDF SDK, follow the steps outlined below: Read the PDF file. Load the page and get the page objects in that page. Use FSPDF_PageObjects_GetObjectAtPos to get the text object in a certain position. Note: use page object get rectangle to see the [...]

    Read Article
    Foxit PDF SDK 5.3

    How to extract the highest solution of an image in a pdf file using Foxit PDF SDK?

    The real size of an image object is inside the dictionary of the pdf file, get the image object and then get the dictionary data for the image object. Here is a simple example: FSCRT_PAGE page = NULL; ret = LoadPage(doc, i, &page); if (FSCRT_ERRCODE_SUCCESS != ret){ printf("Failed to load a given page.n"); return ret; [...]

    Read Article
    News
    Tech

    Introducing MobilePDF SDK 3.0

    We are very proud to introduce version 3.0 of Foxit MobilePDF SDK. This is the first major release of MobilePDF SDK in 2017 and it introduces many important features in the Core API and UI Extensions Component. Get a free 10 day trial of MobilePDF SDK by clicking here. Have a look below for the [...]

    Read Article
    Foxit WebPDF Viewer - Discontinued

    Does Foxit WebPDF Viewer support Docker deployments?

    Yes, Foxit WebPDF Viewer supports Docker deployments. A Docker Image for WebPDF Viewer is provided in the Docker Hub public repository: https://hub.docker.com/r/foxitsoftware/webpdf/ Note: This article refers to a deprecated version of a Foxit Product. If you are still using Foxit WebPDF Viewer, please refer to your download package documents for Developer Guide and API Reference. [...]

    Read Article
    News
    Tech

    Quick PDF Library 13.12, featuring Delphi 10.2 Tokyo support basic ZUGFeRD features and a number of rendering improvements.

    March 29th 2017, we are releasing the latest version of our Quick PDF Library, version 13.12, which adds support for Delphi 10.2 and ZUGFeRD generation, adds rendering and text decoding improvements and includes new form field options to support other string formats. The release also includes a number of bug fixes and other enhancements. Have [...]

    Read Article
    Tech

    How to Show a PDF with Your iOS App Using Foxit Mobile PDF SDK

    Adding the ability to view PDF files to your iOS app is incredibly easy when using Foxit Mobile PDF SDK. This tutorial will show you how with just 10 lines of code and 3 easy steps.

    Read Article
    Foxit PDF SDK 5.3

    Why the length of the string retrieved from interface FSPDF_TextPage_GetChars is different from the count of characters getting from interface FSPDF_TextPage_CountChars?

    The string retrieved from interface FSPDF_TextPage_GetChars is a UTF-8 string. The interface FSPDF_TextPage_CountChars gets the count of characters in a page. “The length of string” and “the count of characters” are two totally different concepts. The length of a UTF-8 string represents how many bytes the UTF-8 string consumes, rather than how many characters the [...]

    Read Article
    Foxit PDF SDK 5.3

    How can I rotate a text object around its center instead of the origin of coordinates?

    Figure 1(a) shows the rotation of a text object around the origin of coordinates in Foxit PDF SDK. If we want to rotate a text object around its center as shown in Figure 1(b), a set of complex transformations are needed. The complete transformation process is shown in Figure 2. First, translate the center of [...]

    Read Article