Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Delete question mark in QML Dialog titlebar

Delete question mark in QML Dialog titlebar

Scheduled Pinned Locked Moved Solved QML and Qt Quick
6 Posts 2 Posters 2.9k Views
  • 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.
  • L Offline
    L Offline
    Locate
    wrote on last edited by A Former User
    #1

    I am using Qt 5.7. In my QML project I have several dialogs. In the titlebar of this dialogs there is a question mark under Windows. Under Mac there is no question mark. Is there a possibility to remove this question marks? Or alternatively is there a Signal to connect a Slot when the question mark is clicked?
    My Dialog is something like this:

    Dialog {
        property string appVersion: ""
        property color buttonColor: "#000000"
        property string branding: ""
    
        id: dlgAppInfo
        visible: true;
        modality: Qt.ApplicationModal
        width: 520
        height: 300
    
        signal signalClose()
        signal signalUpdate(bool silent)
    
        onVisibleChanged: {
            signalClose()
        }
    
        contentItem: Rectangle {
            x: 20
            y: 20
    
    //My components
    }
    }
    

    Edit: Added code tags -- @Wieland

    1 Reply Last reply
    0
    • ? Offline
      ? Offline
      A Former User
      wrote on last edited by
      #2

      Hi! Not sure what question mark you're speaking of. Maybe it goes away when you set the title property of the Dialog?

      1 Reply Last reply
      0
      • L Offline
        L Offline
        Locate
        wrote on last edited by
        #3

        0_1487339487165_Unbenannt.PNG

        Here is a screenshot of such a Dialog. I have marked the question mark. The title property is set.

        ? 1 Reply Last reply
        0
        • L Locate

          0_1487339487165_Unbenannt.PNG

          Here is a screenshot of such a Dialog. I have marked the question mark. The title property is set.

          ? Offline
          ? Offline
          A Former User
          wrote on last edited by
          #4

          @Locate The image upload feature on our forum is broken (the image might be visible to you but not to anyone else). Please use an image hoster (e.g. https://postimage.io) and embed the file here with ![alternate text](url).

          1 Reply Last reply
          0
          • L Offline
            L Offline
            Locate
            wrote on last edited by Locate
            #5

            Here is a link for the Image https://s3.postimg.org/dkjhdm0ab/Unbenannt.png

            alt text

            1 Reply Last reply
            0
            • ? Offline
              ? Offline
              A Former User
              wrote on last edited by
              #6

              I don't think one can customize that for a Dialog. What you could do is to use a Window QML Type as the foundation for your own dialog item. You can customize almost everything with Window. You can change the buttons in the title by modifying the flags property. A list with all window flags can be found here: flags Qt::WindowFlags. And there's also the Window Flags Example.

              1 Reply Last reply
              0

              • Login

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • Users
              • Groups
              • Search
              • Get Qt Extensions
              • Unsolved