Qt Forum

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

    Update: Forum Guidelines & Code of Conduct


    Qt World Summit: Early-Bird Tickets

    Window

    QML and Qt Quick
    4
    7
    1952
    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.
    • M
      mikealfa last edited by

      Can any body tell me how to make the application full screen when clicked on the maximize button ?

      1 Reply Last reply Reply Quote 0
      • T
        tobias.hunger last edited by

        You don't need to do anything. The application will be resized whenever the window size is changed.

        1 Reply Last reply Reply Quote 0
        • M
          mikealfa last edited by

          but what i am saying is i want my window without the title bar.....as in what happens when we double click in the vlc media player

          1 Reply Last reply Reply Quote 0
          • P
            pratik041 last edited by

            [quote author="mikealfa" date="1330517063"]but what i am saying is i want my window without the title bar.....as in what happens when we double click in the vlc media player[/quote]

            You can re implement the @mouseDoubleclickevent()@ and their you can call @showmaximized()@
            function.

            Pratik Agrawal

            1 Reply Last reply Reply Quote 0
            • L
              lgeyer last edited by

              Is think there is no platform-independent way of receiving system menu events, so you will have to reimplement the change event and modify the window state accordingly.
              @
              void MainWindow::changeEvent(QEvent *event)
              {
              if(event->type() == QEvent::WindowStateChange)
              {
              if(windowState() & Qt::WindowMaximized)
              {
              showFullscreen();
              }
              }

              QMainWindow::changeEvent(event);
              

              }
              @
              Brain to terminal. Not tested. Exemplary.

              Two additions:

              • you are tinkering with default behaviour here; the user usually does not expect that a window goes into fullscreen when the maximize button is clicked
              • a fullscreen window has no system menu; you will have to provide other means to return from fullscreen, otherwise you are trapped in it
              1 Reply Last reply Reply Quote 0
              • M
                mikealfa last edited by

                @pratik
                thanks

                1 Reply Last reply Reply Quote 0
                • M
                  mikealfa last edited by

                  @lukas
                  yep...i am doing so because i am developing a game and want it to be fullscreen when clicked on the maximize button

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