Details
-
Bug
-
Resolution: Done
-
P2: Important
-
5.9.0, 5.9.1
-
None
-
Qt 5.9.0 and Qt 5.9.1 (installed using the Qt installer) on Ubuntu 17.04 running on amd64.
Description
Using the following QML the fitViewportToMapItems() method fails to correctly scale the map to show only the present map items. Testing with Qt 5.7.1 shows that this functionality used to work correctly, so this appears to be a regression.
Test code:
Expected result (from Qt 5.7.1):
Actual result (in Qt 5.9.0 and Qt 5.9.1):
The map actually starts at zoomLevel 10, so the fitViewportToMapItems() method is actively zooming out to an incorrect level (rather than just having no effect at all).
I tested with both MapPolylines and MapQuickItems both giving the same results.
Adding a MouseArea and calling fitViewportToMapItems() when clicked results in very inconsistent behaviour, with it sometimes fitting correctly to the path, sometimes zooming all the way out as seen when called on component completion and sometimes only displaying part of the path.
Thanks!
Mike
Attachments
Issue Links
- resulted from
-
QTBUG-65643 Refactor Map.fitViewportToMapItem to operate on tilted maps
- Reported