Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-75331

WebAssembly: Font loading issues (freetype does not seems to be used)

    XMLWordPrintable

Details

    • Bug
    • Resolution: Cannot Reproduce
    • P4: Low
    • None
    • 5.13.0 Beta2
    • QPA
    • None
    • Win 10, Google Chrome Canary (latest), FireFox Nightly (latest)
    • WebAssembly

    Description

      I am trying to reach a state, when a webassembly application loads a font on the fly: it connects to a server via websocket, downloads the font from it and loads it via QFontDatabase->addApplicationFontFromData() function. The font file is a 20MB file (.cid) and could be loaded and used in the Windows standalone application (same source code as for webassembly) after the "WindwosArgument = fontengine=freetype" was defined in qt.conf.

      For the webassemlby tests, all the required headers and libs are present on the compilation server, and the "configure" defines that freetype lib is found and used. Despite this, running a webassembly application compiled using Qt with "-qt-freetype" or "-system-freetype" parameters yields the same result: the addApplicationFontFromData() returns -1 (font cannot be loaded).

      In the compilation output I do see that libfreefont library is linked to the executable, so I assume it is not the case that freetype is not compiled in correctly.

      It might be tha case that I oversee a settings or configuration parameter for webassembly's font handling in Qt. Was it tested with any freetype supported fonts before? Should it work at all?

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            lpotter Lorn Potter
            imrenagy imrenagy
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes