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

Broken text rendering on Android using QML

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P1: Critical
    • None
    • 5.3.0 Alpha
    • QPA
    • None
    • LG Nexus 4, Android 4.4.2, ADT x86_64-20131030, NDK r9d, GNU GCC/G++ 4.8
    • Android

    Description

      Text rendered on a QDeclarativeView (or whatever QQmlApplicationEngine uses, probably the same) appears as irregular black blocks.

      Some characters (usually numbers or punctuation) appear unaffected, but the working characters don't appear to be constant. After restarting the application 4 may render correctly where it didn't before, and 9 may not render properly where it did before.

      The text appears to render correctly on initial load, but on changing the Text.text property text characters (not necessarily on the Text object changed) become unreadable.

      Screenshots for reference, the first on Android (qml-nowork) and the second on Xorg (qml-works).

      The output from runtime is as follows:

      Starting remote process.D/Qt (23314): fontdatabases/basic/qbasicfontdatabase.cpp:238 (static QStringList QBasicFontDatabase::addTTFile(const QByteArray&, const QByteArray&)): FT_New_Face failed with index 0 : 90
      D/Qt (23314): assets:/Flintlock/qml/POS/js/remote.js:113 (): Connecting to [192.168.1.24]:1517
      D/Qt (23314): assets:/Flintlock/qml/POS/js/remote.js:109 (): Connected.
      I/art (23314): Debugger is no longer active

      I've tested using both ART and Dalvik.

      On a fresh start the text is rendered as 'white' rather than the black blocks.

      Buttons imported from QtQuick.Controls 1.1 (qtquickcontrols-opensource-src-5.3.0-alpha) appear to be unaffected as it seems to use its own internal methods of rendering text.

      Appending items to a ListView model which uses a delegate containing Text items also populates correctly (even when other application text is corrupted), but upon text change anywhere on the screen it will also corrupt similarly.

      Minimal sample project attached (qmltexttest.tar.xz). On load it should render as expected. Tap the resulting canvas a few times to reproduce the problem.

      Attachments

        1. qml-nowork.png
          qml-nowork.png
          35 kB
        2. qmltexttest.tar.xz
          11 kB
        3. qml-works.png
          qml-works.png
          60 kB
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            ylopes Yoann Lopes
            doneill d francis o'neill
            Votes:
            2 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes