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

Popup doesn't inherit fonts from Control parents

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Invalid
    • Icon: Not Evaluated Not Evaluated
    • None
    • 5.11
    • Quick: Controls 2
    • None

      It will inherit the window's font, but not a control's:

      import QtQuick 2.9
      import QtQuick.Window 2.2
      import QtQuick.Controls 2.4
      
      ApplicationWindow {
          width: 640
          height: 480
          visible: true
      
          // Works
      //    font.family: "Courier New"
      
      //    Popup {
      //        width: 400
      //        height: 400
      //        visible: true
      
      //        Label {
      //            text: "This Label's font should be Courier New. It is: \"" + font.family + "\""
      //        }
      //    }
      
          Pane {
              font.family: "Courier New"
              anchors.fill: parent
      
              Popup {
                  width: 400
                  height: 400
                  visible: true
      
                  Label {
                      text: "This Label's font should be Courier New. It is: \"" + font.family + "\""
                  }
              }
          }
      }
      

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

            qt.team.quick.subscriptions Qt Quick and Widgets Team
            mitch_curtis Mitch Curtis
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes