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. Screen design problems
Forum Updated to NodeBB v4.3 + New Features

Screen design problems

Scheduled Pinned Locked Moved Solved General and Desktop
17 Posts 3 Posters 1.9k 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.
  • SPlattenS SPlatten

    @AxelVienna I would like to report the font's being used, just something like:

    qDebug() << fontInfo.family();
    qDebug() << fontInfo.pixelSize();
    qDebug() << fontInfo.pointSize();
    

    So I can verify what is being used and its size.

    artwawA Offline
    artwawA Offline
    artwaw
    wrote on last edited by
    #8

    @SPlatten Since you are on Windows - there might be additional issue of desktops scaling per screen I think? At least looks very much alike.

    https://doc.qt.io/qt-5/highdpi.html

    For more information please re-read.

    Kind Regards,
    Artur

    SPlattenS 1 Reply Last reply
    0
    • AxelViennaA Offline
      AxelViennaA Offline
      AxelVienna
      wrote on last edited by
      #9

      Well, if everything is the same on both screens, the issue is screen scaling on desktop level as @artwaw correctly said. You will find it out by trying a totally different executable, e.g. Microsoft Excel and see if it behaves the same.

      @SPlatten: Regarding your homemade widgets, my suspicion is that they simply do not resize. This can result from multiple reasons, including that no resize methods have been implemented for them.

      C++ and Python walk into a bar. C++ reuses the first glass.

      SPlattenS 1 Reply Last reply
      0
      • AxelViennaA AxelVienna

        Well, if everything is the same on both screens, the issue is screen scaling on desktop level as @artwaw correctly said. You will find it out by trying a totally different executable, e.g. Microsoft Excel and see if it behaves the same.

        @SPlatten: Regarding your homemade widgets, my suspicion is that they simply do not resize. This can result from multiple reasons, including that no resize methods have been implemented for them.

        SPlattenS Offline
        SPlattenS Offline
        SPlatten
        wrote on last edited by SPlatten
        #10

        @AxelVienna The widgets are in the correct position and size on each render, the only issue is the text labels in the QGroupBoxes which appear to small for the labels.

        Kind Regards,
        Sy

        1 Reply Last reply
        0
        • AxelViennaA Offline
          AxelViennaA Offline
          AxelVienna
          wrote on last edited by
          #11

          @SPlatten: Okay. My suspicion comes from the fact that their headings do not seem to be centered. "Marquage Stagaire" right from the center. Which kind of layout does the QGroupBox "Stagaire" have? And what is the size policy of the QComboBox next to "Stagaire a voir"?

          C++ and Python walk into a bar. C++ reuses the first glass.

          1 Reply Last reply
          0
          • SPlattenS Offline
            SPlattenS Offline
            SPlatten
            wrote on last edited by
            #12

            @AxelVienna , those widgets don't use layouts at all, they are rendered to an offscreen painter then copied as an image to the visible area.

            Kind Regards,
            Sy

            artwawA 1 Reply Last reply
            0
            • SPlattenS SPlatten

              @AxelVienna , those widgets don't use layouts at all, they are rendered to an offscreen painter then copied as an image to the visible area.

              artwawA Offline
              artwawA Offline
              artwaw
              wrote on last edited by
              #13

              @SPlatten I think that's the culprit - layouts provide proper scaling and resize. But I have no idea how can you overcome that using already implemented approach.

              For more information please re-read.

              Kind Regards,
              Artur

              SPlattenS 1 Reply Last reply
              0
              • artwawA artwaw

                @SPlatten I think that's the culprit - layouts provide proper scaling and resize. But I have no idea how can you overcome that using already implemented approach.

                SPlattenS Offline
                SPlattenS Offline
                SPlatten
                wrote on last edited by
                #14

                @artwaw , don't get distracted those widgets have nothing to do with the group boxes that have labels that don't fit.

                Kind Regards,
                Sy

                1 Reply Last reply
                0
                • artwawA artwaw

                  @SPlatten Since you are on Windows - there might be additional issue of desktops scaling per screen I think? At least looks very much alike.

                  https://doc.qt.io/qt-5/highdpi.html

                  SPlattenS Offline
                  SPlattenS Offline
                  SPlatten
                  wrote on last edited by SPlatten
                  #15

                  @artwaw said in Screen design problems:

                  https://doc.qt.io/qt-5/highdpi.html

                  Looking at that link it shows;

                  <application> -platform windows:dpiawareness=0,1,2
                  

                  How does this translate into an entry in the qt.conf file? I've added:

                  [Platforms]
                  

                  Not sure what the actual configuration should look like.

                  [edit] I found something online, not sure if its correct, have edited qt.conf in C:\Qt\Qt5.9.2\5.9.2\msvc2015_64\bin\qt.conf:

                  [Platforms]
                  WindowsArguments = dip awareness = 0
                  

                  Kind Regards,
                  Sy

                  artwawA 1 Reply Last reply
                  0
                  • SPlattenS SPlatten

                    @artwaw said in Screen design problems:

                    https://doc.qt.io/qt-5/highdpi.html

                    Looking at that link it shows;

                    <application> -platform windows:dpiawareness=0,1,2
                    

                    How does this translate into an entry in the qt.conf file? I've added:

                    [Platforms]
                    

                    Not sure what the actual configuration should look like.

                    [edit] I found something online, not sure if its correct, have edited qt.conf in C:\Qt\Qt5.9.2\5.9.2\msvc2015_64\bin\qt.conf:

                    [Platforms]
                    WindowsArguments = dip awareness = 0
                    
                    artwawA Offline
                    artwawA Offline
                    artwaw
                    wrote on last edited by
                    #16

                    @SPlatten WindowsArguments = or Windows = I think.

                    https://doc.qt.io/qt-5/qt-conf.html

                    For more information please re-read.

                    Kind Regards,
                    Artur

                    SPlattenS 1 Reply Last reply
                    1
                    • artwawA artwaw

                      @SPlatten WindowsArguments = or Windows = I think.

                      https://doc.qt.io/qt-5/qt-conf.html

                      SPlattenS Offline
                      SPlattenS Offline
                      SPlatten
                      wrote on last edited by
                      #17

                      @artwaw said in Screen design problems:

                      https://doc.qt.io/qt-5/qt-conf.html

                      Thank you, I've also used the command line option:

                      -platform windows:dipawareness=0
                      

                      Which works.

                      Kind Regards,
                      Sy

                      1 Reply Last reply
                      1

                      • Login

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