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. QT Design Full Screen
Forum Updated to NodeBB v4.3 + New Features

QT Design Full Screen

Scheduled Pinned Locked Moved Solved General and Desktop
10 Posts 3 Posters 2.6k Views 2 Watching
  • 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.
  • beautifulcloudB Offline
    beautifulcloudB Offline
    beautifulcloud
    wrote on last edited by
    #1

    Hello people,

    I just started with QT Design, I have an instruction in my main.cpp to make my window full screen :

        MainWindow w;
        w.showFullScreen();
        w.show();
    

    But I don't understand how to adapt the size of Qt design to the same size as a 1920x1080 screen, I tried several things in geometry but it doesn't work.

    Result: if I create a button and put it at the edge of the Qt design window, it will be in the center in my real window. Or if I maximize the Qt design window and put the button at the edge it will no longer be visible in my final window

    QT design :
    3e6623ee-aef0-46be-9025-b16f751f36e0-image.png

    Result window :
    7c3a2c3a-7d41-4180-b336-e35dfee0aee1-image.png

    Besides if someone can tell me if there is a possibility to zoom out that would be cool ^^'

    Thank you

    M 1 Reply Last reply
    0
    • beautifulcloudB beautifulcloud

      @mpergand
      I don't understand, there is not category for layout when the selection of central widget?

      0f537e3b-aa34-4b3c-b45a-c03dbf60d6e9-image.png

      isn't the layout already created?
      Sorry if I don't understand well

      M Offline
      M Offline
      mpergand
      wrote on last edited by mpergand
      #6

      @beautifulcloud
      You need to select the background widget, you will see MainWindow selected in the tree view on the right.
      Then the Layout menu item is available.
      Or you can click on MainWindow in the tree view directly.

      isn't the layout already created?

      the symbol "sens interdit" tells you is not ;)

      beautifulcloudB 1 Reply Last reply
      1
      • beautifulcloudB beautifulcloud

        Hello people,

        I just started with QT Design, I have an instruction in my main.cpp to make my window full screen :

            MainWindow w;
            w.showFullScreen();
            w.show();
        

        But I don't understand how to adapt the size of Qt design to the same size as a 1920x1080 screen, I tried several things in geometry but it doesn't work.

        Result: if I create a button and put it at the edge of the Qt design window, it will be in the center in my real window. Or if I maximize the Qt design window and put the button at the edge it will no longer be visible in my final window

        QT design :
        3e6623ee-aef0-46be-9025-b16f751f36e0-image.png

        Result window :
        7c3a2c3a-7d41-4180-b336-e35dfee0aee1-image.png

        Besides if someone can tell me if there is a possibility to zoom out that would be cool ^^'

        Thank you

        M Offline
        M Offline
        mpergand
        wrote on last edited by
        #2

        @beautifulcloud
        Salut,
        It' unclear how your widgets are arranged (layout).
        STP, post a screenshhot of the Designer window included the object tree panel on the right.

        beautifulcloudB 1 Reply Last reply
        1
        • M mpergand

          @beautifulcloud
          Salut,
          It' unclear how your widgets are arranged (layout).
          STP, post a screenshhot of the Designer window included the object tree panel on the right.

          beautifulcloudB Offline
          beautifulcloudB Offline
          beautifulcloud
          wrote on last edited by
          #3

          Salut @mpergand,

          Here is a screenshot of my interface :
          46f8d0cf-3c65-469a-bf88-86194137eb3e-image.png

          Here is a screenshot of the window after compilation :
          9ce7022f-0e04-4ce8-b8d6-e5335ce213a6-image.png

          As you can see the third button added in QT Design is not displayed in the window because they are not the same size

          M 1 Reply Last reply
          0
          • beautifulcloudB beautifulcloud

            Salut @mpergand,

            Here is a screenshot of my interface :
            46f8d0cf-3c65-469a-bf88-86194137eb3e-image.png

            Here is a screenshot of the window after compilation :
            9ce7022f-0e04-4ce8-b8d6-e5335ce213a6-image.png

            As you can see the third button added in QT Design is not displayed in the window because they are not the same size

            M Offline
            M Offline
            mpergand
            wrote on last edited by
            #4

            @beautifulcloud
            You must add a layout for the central widget:
            Right-click on it then Layout->Layout vertically

            beautifulcloudB 1 Reply Last reply
            2
            • M mpergand

              @beautifulcloud
              You must add a layout for the central widget:
              Right-click on it then Layout->Layout vertically

              beautifulcloudB Offline
              beautifulcloudB Offline
              beautifulcloud
              wrote on last edited by
              #5

              @mpergand
              I don't understand, there is not category for layout when the selection of central widget?

              0f537e3b-aa34-4b3c-b45a-c03dbf60d6e9-image.png

              isn't the layout already created?
              Sorry if I don't understand well

              M 1 Reply Last reply
              0
              • beautifulcloudB beautifulcloud

                @mpergand
                I don't understand, there is not category for layout when the selection of central widget?

                0f537e3b-aa34-4b3c-b45a-c03dbf60d6e9-image.png

                isn't the layout already created?
                Sorry if I don't understand well

                M Offline
                M Offline
                mpergand
                wrote on last edited by mpergand
                #6

                @beautifulcloud
                You need to select the background widget, you will see MainWindow selected in the tree view on the right.
                Then the Layout menu item is available.
                Or you can click on MainWindow in the tree view directly.

                isn't the layout already created?

                the symbol "sens interdit" tells you is not ;)

                beautifulcloudB 1 Reply Last reply
                1
                • M mpergand

                  @beautifulcloud
                  You need to select the background widget, you will see MainWindow selected in the tree view on the right.
                  Then the Layout menu item is available.
                  Or you can click on MainWindow in the tree view directly.

                  isn't the layout already created?

                  the symbol "sens interdit" tells you is not ;)

                  beautifulcloudB Offline
                  beautifulcloudB Offline
                  beautifulcloud
                  wrote on last edited by
                  #7

                  @mpergand
                  Now it seems to be more structured and more adapted to the size of the screen. My buttons are centered I will see if it is possible to put them at the bottom left while keeping this configuration
                  2ba4c09f-7337-4489-bcb9-d213638dea92-image.png
                  Thanks for your help :)

                  M Pl45m4P 2 Replies Last reply
                  0
                  • beautifulcloudB beautifulcloud has marked this topic as solved on
                  • beautifulcloudB beautifulcloud

                    @mpergand
                    Now it seems to be more structured and more adapted to the size of the screen. My buttons are centered I will see if it is possible to put them at the bottom left while keeping this configuration
                    2ba4c09f-7337-4489-bcb9-d213638dea92-image.png
                    Thanks for your help :)

                    M Offline
                    M Offline
                    mpergand
                    wrote on last edited by mpergand
                    #8

                    @beautifulcloud
                    Right-click on the button and choose Layout alignment-> Left
                    then Layout alignment-> bottom

                    1 Reply Last reply
                    1
                    • beautifulcloudB beautifulcloud

                      @mpergand
                      Now it seems to be more structured and more adapted to the size of the screen. My buttons are centered I will see if it is possible to put them at the bottom left while keeping this configuration
                      2ba4c09f-7337-4489-bcb9-d213638dea92-image.png
                      Thanks for your help :)

                      Pl45m4P Offline
                      Pl45m4P Offline
                      Pl45m4
                      wrote on last edited by Pl45m4
                      #9

                      @beautifulcloud said in QT Design Full Screen:

                      put them at the bottom left while keeping this configuration

                      You can push your button layout to the bottom-left with spacers.
                      One vertical spacer above the button box to push it down and one horizontal spacer right to it to push it to the left. But depends all on what else you want to add to your window.


                      If debugging is the process of removing software bugs, then programming must be the process of putting them in.

                      ~E. W. Dijkstra

                      beautifulcloudB 1 Reply Last reply
                      1
                      • Pl45m4P Pl45m4

                        @beautifulcloud said in QT Design Full Screen:

                        put them at the bottom left while keeping this configuration

                        You can push your button layout to the bottom-left with spacers.
                        One vertical spacer above the button box to push it down and one horizontal spacer right to it to push it to the left. But depends all on what else you want to add to your window.

                        beautifulcloudB Offline
                        beautifulcloudB Offline
                        beautifulcloud
                        wrote on last edited by
                        #10

                        @Pl45m4
                        Thanks for your help both,

                        Here is what I did :
                        afe4edac-f73d-4901-9b1b-21b10010653b-image.png

                        07458596-b68c-48b4-a4e3-b7a7380f0288-image.png

                        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