Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    Qt Academy Launch in California!

    Unsolved Text's fontFamily property invalid in QML

    QML and Qt Quick
    font family text qml
    2
    2
    755
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • W
      wangzhe last edited by p3c0

      Text's fontFamily property invalid in QML

      I used Text in a qml file like this:

      Text{
             id: text
             font.family: "Roboto-Regular"
      }
      

      When I used the qt-mingw, it can show correctly, but when I used the qt-msvc. It show the qt's default font family. Please help me, thanks

      1 Reply Last reply Reply Quote 0
      • dheerendra
        dheerendra Qt Champions 2022 last edited by

        Looks strange. There is one example called fontDatabase in Qt examples. Can you compile in msvc and check this font is available ?

        Dheerendra
        @Community Service
        Certified Qt Specialist
        http://www.pthinks.com

        1 Reply Last reply Reply Quote 0
        • First post
          Last post