Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-111787

devicePixelRatio / zoom rescale error

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P2: Important
    • 6.7.0 FF
    • 6.4.2
    • GUI: High-DPI
    • None
    • Qt 6.4.2
      Chrome x64 110.0.5481.178
      Firefox x64 110.0
      Emscripten 3.1.14
      Windows 10
    • WebAssembly
    • 9e740c726 (dev)

    Description

      Hello, I have a bug that I don't understand.

      When using chrome without zoom window.devicePixelRatio return 1 and my application is well rendered.

      When I zoom out (for exemple 25%) window.devicePixelRatio return 0.25 and my application is rendered with a x4 factor.

      When I zoom in (for exemple 500%) windows.devicePixelRatio return 5 and my application is rendered with a /5 factor.

      (same results with firefox)

       

      Is there a way to to reverse the factor ? When zooming-out, I want my app to reduce it's size.

       

      To be precise, I think the zoom-in behavior work as expected because the canvas use a width and height of 100%, but the actual zoom-out behavior scale the app outside of the browser viewport  

      Attachments

        For Gerrit Dashboard: QTBUG-111787
        # Subject Branch Project Status CR V

        Activity

          People

            sorvig Morten Sørvig
            bastien-thonnat-personal Bastien Thonnat
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes