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. QWindowsWindow::setGeometry: Unable to set geometry 480x720+-2615+657

QWindowsWindow::setGeometry: Unable to set geometry 480x720+-2615+657

Scheduled Pinned Locked Moved Unsolved General and Desktop
8 Posts 3 Posters 2.3k 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 Offline
    SPlattenS Offline
    SPlatten
    wrote on last edited by
    #1

    I have a form that when its displayed I get a message in the console. I've remove the code that was setting the geometry, cleaned and rebuilt but I'm still seeing this message displayed when the form is displayed:

    QWindowsWindow:setGeometry: Unable to set geometry 480x720+-2615+657 on QWidgetWindow/'DataSetsClassWindow' .Resulting geometry: 480x720+-2615+657 (frame: 8, 31, 8, 8, custom margin: 0, 0, 0, 0, minimum size: 480x490, maximum size: 16777215x16777215).
    

    The screen this is running on has the resolution: 5120x1140

    Kind Regards,
    Sy

    1 Reply Last reply
    0
    • Kent-DorfmanK Online
      Kent-DorfmanK Online
      Kent-Dorfman
      wrote on last edited by
      #2

      That doesn't look right. Assuming the syntax is taken from X11 then +- is probably where your problem is. I think + and - are used separately to indicate offset from upper left and lower right screen limits.

      HxW+x+y from upper left
      HxW-x-y from lower right

      If you meet the AI on the road, kill it.

      SPlattenS 1 Reply Last reply
      0
      • Kent-DorfmanK Kent-Dorfman

        That doesn't look right. Assuming the syntax is taken from X11 then +- is probably where your problem is. I think + and - are used separately to indicate offset from upper left and lower right screen limits.

        HxW+x+y from upper left
        HxW-x-y from lower right

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

        @Kent-Dorfman , that was taken from the console output so the output is as displayed.

        Kind Regards,
        Sy

        JonBJ 1 Reply Last reply
        0
        • SPlattenS SPlatten

          @Kent-Dorfman , that was taken from the console output so the output is as displayed.

          JonBJ Offline
          JonBJ Offline
          JonB
          wrote on last edited by
          #4

          @SPlatten
          One thought: I am guessing that the -2615 is what it doesn't like.

          I've remove the code that was setting the geometry

          Is there any chance that in time you will come back to this and say "Actually I just found I did not remove every geometry, there was one left"? Or, is there any chance you have previously saved the geometry and are trying to restore it (QWidget::restoreGeometry())?

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

            @JonB , I've checked the source, I'm not calling setGeometry, there are no instances of QRect, no mention of geom in the class, searching with case insensitive.

            Kind Regards,
            Sy

            JonBJ 1 Reply Last reply
            0
            • SPlattenS SPlatten

              @JonB , I've checked the source, I'm not calling setGeometry, there are no instances of QRect, no mention of geom in the class, searching with case insensitive.

              JonBJ Offline
              JonBJ Offline
              JonB
              wrote on last edited by JonB
              #6

              @SPlatten
              Then although you do not say what version of Qt you are using, a simple Google suggests you are on something like 5.12 and your issue is described in, say, https://stackoverflow.com/questions/54307407/why-am-i-getting-qwindowswindowsetgeometry-unable-to-set-geometry-warning-wit ?

              SPlattenS 1 Reply Last reply
              0
              • JonBJ JonB

                @SPlatten
                Then although you do not say what version of Qt you are using, a simple Google suggests you are on something like 5.12 and your issue is described in, say, https://stackoverflow.com/questions/54307407/why-am-i-getting-qwindowswindowsetgeometry-unable-to-set-geometry-warning-wit ?

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

                @JonB , the version of Qt is 5.9.2 MSVC2015 32bit, I'm not in a position to upgrade Qt either as I'm using a clients laptop and the IT is tightly controlled.

                Kind Regards,
                Sy

                JonBJ 1 Reply Last reply
                0
                • SPlattenS SPlatten

                  @JonB , the version of Qt is 5.9.2 MSVC2015 32bit, I'm not in a position to upgrade Qt either as I'm using a clients laptop and the IT is tightly controlled.

                  JonBJ Offline
                  JonBJ Offline
                  JonB
                  wrote on last edited by
                  #8

                  @SPlatten
                  Well, I suggest nonetheless you Google as there are quite a few hits going back over time. Just for example https://bugreports.qt.io/browse/QTBUG-58027 mentions

                  i met the same issue when i upgrade the version to qt5.9.2, my previous version is 5.7.

                  It seems to be a warning some people get. Some suggestions that setting a minimum size helps.

                  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