Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Fullscreen QML application is flickering when hovering or pressing a button

Fullscreen QML application is flickering when hovering or pressing a button

Scheduled Pinned Locked Moved General and Desktop
qmlwindowsfullscreenflickering
5 Posts 3 Posters 4.5k 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.
  • D Offline
    D Offline
    D.Fahsig
    wrote on 29 Sept 2015, 05:36 last edited by D.Fahsig
    #1

    I have a fullscreen QML application that should be displaying a dialog.
    Whenever I hover or click on a button the screen flickers like the graphics card was switching modes or something.
    This also happens with a demo application that is started standalone or with qmlscene.

    System: Qt 5.5.0 on Windows 7 SP1 x64 (and x86)

    main.qml:

    import QtQuick 2.4
    import QtQuick.Dialogs 1.2
    import QtQuick.Window 2.2
    import QtQuick.Controls 1.3
    
    ApplicationWindow {
        visible: true
        Rectangle {
            anchors.fill: parent
            Rectangle{
                width: 200
                height: 200
                color: "#00ff00"
                Button{
                    id: mouseArea
                    anchors.fill: parent
                    onClicked: {
                       messageDialog.show("Test")
                    }
                }
            }
        }
    
        MessageDialog {
            id: messageDialog
            title: qsTr("May I have your attention, please?")
    
            function show(caption) {
                messageDialog.text = caption;
                messageDialog.open();
            }
        }
    }
    

    Standalone the application is started using QQuickWindow->showFullScreen() (the same code that is used in qmlscene)

    How do I fix that flickering?
    As a workaround I currently have the application running frameless and 1px smaller in height than the screen. Then no flickering occurs, but this is not really what I want. Is there some hidden setting, that makes this work on windows? (Apparently this is a windows-only problem)

    1 Reply Last reply
    0
    • A Offline
      A Offline
      AndreasM
      wrote on 9 Oct 2015, 12:09 last edited by AndreasM 10 Sept 2015, 12:09
      #2

      Hi,

      wie have the same issue. Anybody else having that issue and can provide a fix/solution/workaround?

      V 1 Reply Last reply 9 Oct 2015, 12:11
      0
      • A AndreasM
        9 Oct 2015, 12:09

        Hi,

        wie have the same issue. Anybody else having that issue and can provide a fix/solution/workaround?

        V Offline
        V Offline
        vishnu
        wrote on 9 Oct 2015, 12:11 last edited by
        #3

        @AndreasM
        can you try like this

        import QtQuick.Window 2.2
        ApplicationWindow{
            id:windows
            width: Screen.width
            height: Screen.height
        }
        
        D 1 Reply Last reply 12 Oct 2015, 08:24
        0
        • V vishnu
          9 Oct 2015, 12:11

          @AndreasM
          can you try like this

          import QtQuick.Window 2.2
          ApplicationWindow{
              id:windows
              width: Screen.width
              height: Screen.height
          }
          
          D Offline
          D Offline
          D.Fahsig
          wrote on 12 Oct 2015, 08:24 last edited by
          #4

          @vishnu
          This leads to the same situation. Qt or windows seems to recognize an application filling the complete screen and makes it fullscreen, if it is borderless. If it is not borderless this does not work as parts of the application go offscreen by the amount of pixels used by the top bar and borders.

          V 1 Reply Last reply 12 Oct 2015, 08:28
          0
          • D D.Fahsig
            12 Oct 2015, 08:24

            @vishnu
            This leads to the same situation. Qt or windows seems to recognize an application filling the complete screen and makes it fullscreen, if it is borderless. If it is not borderless this does not work as parts of the application go offscreen by the amount of pixels used by the top bar and borders.

            V Offline
            V Offline
            vishnu
            wrote on 12 Oct 2015, 08:28 last edited by
            #5

            @D.Fahsig
            I am not sure where is the error but it works for me .May be try reinstalling the Qt with necessary components may fix some times. Good luck
            FYI: i also Qt 5.5 on windows 7 64 bit.

            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