Setting font from TTF file in external memory

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • Setting font from TTF file in external memory

    Hi,
    Is there any API's available to set font by reading TTF directly from external memory. currently we are converting TTF file to C using font converter and set font by using TEXT_SetFont().
  • Hi,

    Yes there is such an API. Please refer to chapter 11.3.5 'TrueType Font (TTF) format' of the emWin user manual (UM03001_emWin5.pdf). There you will find information regarding how to use TTF and a link to the TTF library.

    Further you schould check chapter 11.7.3 'TTF file related font functions' for the API description.

    Regards,
    Sven
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.
  • Thanks for your reply :)
    1. We were trying to use GUI_TTF_CreateFontAA(), but this is causing overlap for large text (eg: "another name ABCDDD" where ABCDD is getting overlapped )
    2. could you please explain more about PixelHeight.

    3. Shall we create and use fonts from two different TTF files in a single file scope. we are facing problems such that only font from first TTF file is displaying, fonts from second is not displaying.