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

Qml Location Map visibleRegion property isn't well documented

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Need More Info
    • Priority: P3: Somewhat important
    • Resolution: Incomplete
    • Affects Version/s: 5.12.3
    • Fix Version/s: None
    • Labels:
      None
    • Platform/s:
      All

      Description

      It doesn't seem to very clear what visible region is or how it can be used.

      It need the visible region to construct a coordinate system for an UTM Overlay. Works perfect, but I cannot figure out how the qvisibleRegion works exactly even with reading the sourcecode. IMHO visibleRegion should be (that is what I'm currently using):

      Map {
        id: mapBase
      
        onCenterChanged: {
          var region = QtPositioning.path();
          region.addCoordinate(mapBase.toCoordinate(Qt.point(0, 0)));
          region.addCoordinate(mapBase.toCoordinate(Qt.point(width, 0)));
          region.addCoordinate(mapBase.toCoordinate(Qt.point(width, height)));
          region.addCoordinate(mapBase.toCoordinate(Qt.point(0, height)));
      
          utmOverlay.visibleRegion = region
        }
      }
      
      UTMOverlay {
        id: utmOverlay
      }

      The visibleRegion of Map also delivers a polygon but it is not clear how it correlates to the screen coordinates. This is very important if one wants to use visibleRegion for the construction of an overlay component/mapping coordinate transformation.

       

       

       

        Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

            Assignee:
            paangele Paolo Angelelli
            Reporter:
            kbee Andor Greissl
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes